early-access version 2325

This commit is contained in:
pineappleEA
2021-12-18 11:14:57 +01:00
parent 66c22ff5a2
commit cdbc28f0d4
74 changed files with 7922 additions and 5076 deletions

View File

@@ -53,7 +53,6 @@ typedef LONG NTSTATUS;
#define memset SDL_memset
#define strcmp SDL_strcmp
#define strlen SDL_strlen
#define strncpy SDL_strlcpy
#define strstr SDL_strstr
#define strtol SDL_strtol
#define wcscmp SDL_wcscmp
@@ -105,9 +104,6 @@ extern "C" {
#define MIN(x,y) ((x) < (y)? (x): (y))
#ifdef _MSC_VER
/* Thanks Microsoft, but I know how to use strncpy(). */
#pragma warning(disable:4996)
/* Yes, we have some unreferenced formal parameters */
#pragma warning(disable:4100)
#endif
@@ -550,8 +546,7 @@ struct hid_device_info HID_API_EXPORT * HID_API_CALL hid_enumerate(unsigned shor
if (str) {
len = strlen(str);
cur_dev->path = (char*) calloc(len+1, sizeof(char));
strncpy(cur_dev->path, str, len+1);
cur_dev->path[len] = '\0';
memcpy(cur_dev->path, str, len+1);
}
else
cur_dev->path = NULL;