Skip to content

Commit

Permalink
deps: use nghttp2's config.h on all platforms
Browse files Browse the repository at this point in the history
Fix warnings about use of htonl(), etc. by including config.h for all
platforms, defining HAVE_ARPA_INET_H on non-Windows, and therefore
including <arpa/inet.h>, which defines the host to network byte order
conversion functions.
  • Loading branch information
sam-github committed Apr 18, 2019
1 parent 2948e96 commit 454d6dd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion deps/nghttp2/lib/includes/config.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,9 @@ typedef intptr_t ssize_t;
/* #undef NOTHREADS */

/* Define to 1 if you have the <arpa/inet.h> header file. */
/* #undef HAVE_ARPA_INET_H */
#ifndef _WIN32
# define HAVE_ARPA_INET_H 1
#endif

/* Define to 1 if you have the <fcntl.h> header file. */
#define HAVE_FCNTL_H 1
Expand Down
2 changes: 1 addition & 1 deletion deps/nghttp2/nghttp2.gyp
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@
'defines': [
'BUILDING_NGHTTP2',
'NGHTTP2_STATICLIB',
'HAVE_CONFIG_H',
],
'conditions': [
['OS=="win"', {
'defines': [
'WIN32',
'_WINDOWS',
'HAVE_CONFIG_H',
],
'msvs_settings': {
'VCCLCompilerTool': {
Expand Down

0 comments on commit 454d6dd

Please sign in to comment.