mirror of
https://git.kernel.org/pub/scm/bluetooth/bluez.git
synced 2024-11-16 16:54:38 +08:00
emulator: Fix AMP emulation build error
This fix build with GCC 4.6.3. CC emulator/amp.o emulator/amp.c: In function ‘send_packet’: emulator/amp.c:172:7: error: ignoring return value of ‘write’, declared with attribute warn_unused_result [-Werror=unused-result] cc1: all warnings being treated as errors make[1]: *** [emulator/amp.o] Error
This commit is contained in:
parent
1cbb3e88be
commit
0b24507b8a
@ -169,7 +169,8 @@ static void reset_defaults(struct bt_amp *amp)
|
||||
|
||||
static void send_packet(struct bt_amp *amp, const void *data, uint16_t len)
|
||||
{
|
||||
write(amp->vhci_fd, data, len);
|
||||
if (write(amp->vhci_fd, data, len) < 0)
|
||||
fprintf(stderr, "Write to /dev/vhci failed\n");
|
||||
}
|
||||
|
||||
static void send_event(struct bt_amp *amp, uint8_t event,
|
||||
|
Loading…
Reference in New Issue
Block a user