Skip to content

Commit

Permalink
Merge pull request DaveGamble#518 from fpnuseis/master
Browse files Browse the repository at this point in the history
fix: windows build failure about defining nan
  • Loading branch information
Alanscut committed Oct 16, 2020
2 parents d273527 + 9931900 commit 488169f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cJSON.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,12 @@
#endif

#ifndef NAN
#ifdef _WIN32
#define NAN sqrt(-1.0)
#else
#define NAN 0.0/0.0
#endif
#endif

typedef struct {
const unsigned char *json;
Expand Down

0 comments on commit 488169f

Please sign in to comment.