Skip to content

Commit 1321b6c

Browse files
committed
update headers from latest SDL2.
1 parent 0134073 commit 1321b6c

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

include/SDL2/SDL_stdinc.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -750,8 +750,12 @@ size_t wcslcpy(wchar_t *dst, const wchar_t *src, size_t size);
750750
size_t wcslcat(wchar_t *dst, const wchar_t *src, size_t size);
751751
#endif
752752

753+
#ifndef _WIN32
753754
/* strdup is not ANSI but POSIX, and its prototype might be hidden... */
755+
/* not for windows: might conflict with string.h where strdup may have
756+
* dllimport attribute: https://github.com/libsdl-org/SDL/issues/12948 */
754757
char *strdup(const char *str);
758+
#endif
755759

756760
/* Starting LLVM 16, the analyser errors out if these functions do not have
757761
their prototype defined (clang-diagnostic-implicit-function-declaration) */

0 commit comments

Comments
 (0)