Skip to content

Commit

Permalink
Define PTRDIFF_MAX if it's not in stdint.h
Browse files Browse the repository at this point in the history
Seems to be the case on HP-UX
  • Loading branch information
perlpunk committed Dec 2, 2017
1 parent e5aadc7 commit 5402428
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/yaml_private.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,13 @@

#ifndef _MSC_VER
#include <stdint.h>
#ifndef PTRDIFF_MAX /* gcc on HP-UX sucks */
#ifdef _LP64
#define PTRDIFF_MAX 0x7FFFFFFFFFFFFFFFLL
#else
#define PTRDIFF_MAX 0x7FFFFFFFL
#endif
#endif
#else
#ifdef _WIN64
#define PTRDIFF_MAX _I64_MAX
Expand Down

0 comments on commit 5402428

Please sign in to comment.