Skip to content

Commit 8588168

Browse files
Fix API definitions for clang/gcc flag -Wstrict-prototypes (#533)
1 parent 9f185ec commit 8588168

4 files changed

Lines changed: 8 additions & 8 deletions

File tree

libusb/hid.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -526,12 +526,12 @@ static char *make_path(libusb_device *dev, int config_number, int interface_numb
526526
return strdup(str);
527527
}
528528

529-
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version()
529+
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version(void)
530530
{
531531
return &api_version;
532532
}
533533

534-
HID_API_EXPORT const char* HID_API_CALL hid_version_str()
534+
HID_API_EXPORT const char* HID_API_CALL hid_version_str(void)
535535
{
536536
return HID_API_VERSION_STR;
537537
}

linux/hid.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -808,12 +808,12 @@ static struct hid_device_info * create_device_info_for_hid_device(hid_device *de
808808
return root;
809809
}
810810

811-
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version()
811+
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version(void)
812812
{
813813
return &api_version;
814814
}
815815

816-
HID_API_EXPORT const char* HID_API_CALL hid_version_str()
816+
HID_API_EXPORT const char* HID_API_CALL hid_version_str(void)
817817
{
818818
return HID_API_VERSION_STR;
819819
}

mac/hid.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -417,12 +417,12 @@ static int init_hid_manager(void)
417417
return -1;
418418
}
419419

420-
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version()
420+
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version(void)
421421
{
422422
return &api_version;
423423
}
424424

425-
HID_API_EXPORT const char* HID_API_CALL hid_version_str()
425+
HID_API_EXPORT const char* HID_API_CALL hid_version_str(void)
426426
{
427427
return HID_API_VERSION_STR;
428428
}

windows/hid.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -331,12 +331,12 @@ static HANDLE open_device(const wchar_t *path, BOOL open_rw)
331331
return handle;
332332
}
333333

334-
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version()
334+
HID_API_EXPORT const struct hid_api_version* HID_API_CALL hid_version(void)
335335
{
336336
return &api_version;
337337
}
338338

339-
HID_API_EXPORT const char* HID_API_CALL hid_version_str()
339+
HID_API_EXPORT const char* HID_API_CALL hid_version_str(void)
340340
{
341341
return HID_API_VERSION_STR;
342342
}

0 commit comments

Comments
 (0)