Skip to content

Commit 0dfd2dd

Browse files
committed
Fixes mpaland#95: Now always including limits.h (as we use INT_MAX as a default upper bound on buffer sizes, due to the int return type of printf()-family functions). Thanks goes to Phillip Johnston <phillip@embeddedartistry.com>.
1 parent 52a58b6 commit 0dfd2dd

File tree

1 file changed

+0
-8
lines changed

1 file changed

+0
-8
lines changed

src/printf/printf.c

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -38,16 +38,12 @@
3838

3939
#ifdef __cplusplus
4040
#include <cstdint>
41-
#ifdef PRINTF_SUPPORT_MSVC_STYLE_INTEGER_SPECIFIERS
4241
#include <climits>
43-
#endif
4442
extern "C" {
4543
#else
4644
#include <stdbool.h>
4745
#include <stdint.h>
48-
#ifdef PRINTF_SUPPORT_MSVC_STYLE_INTEGER_SPECIFIERS
4946
#include <limits.h>
50-
#endif
5147
#endif // __cplusplus
5248

5349
// Define this globally (e.g. gcc -DPRINTF_INCLUDE_CONFIG_H ...) to include the
@@ -62,10 +58,6 @@ extern "C" {
6258

6359
#include <stdbool.h>
6460
#include <stdint.h>
65-
#ifdef PRINTF_SUPPORT_MSVC_STYLE_INTEGER_SPECIFIERS
66-
#include <limits.h>
67-
#endif
68-
6961

7062
#include <printf/printf.h>
7163

0 commit comments

Comments
 (0)