Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Unified Diff: native_client_sdk/src/libraries/nacl_io/syscalls/inet_pton.c

Issue 139283003: [NaCl SDK] nacl_io: Fix inet_ntop to be consistent with glibc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: native_client_sdk/src/libraries/nacl_io/syscalls/inet_pton.c
diff --git a/native_client_sdk/src/libraries/nacl_io/syscalls/inet_pton.c b/native_client_sdk/src/libraries/nacl_io/syscalls/inet_pton.c
index b1a2d7a17b4859a5123faa038b4aa40f39b3f795..91d3c6cef56cccbc8544ff2b936d2ab51da04657 100644
--- a/native_client_sdk/src/libraries/nacl_io/syscalls/inet_pton.c
+++ b/native_client_sdk/src/libraries/nacl_io/syscalls/inet_pton.c
@@ -13,8 +13,8 @@
#include "sdk_util/macros.h"
enum {
-kIpv4AddressSize = 4,
-kIpv6AddressSize = 16,
+ kIpv4AddressSize = sizeof(in_addr_t),
+ kIpv6AddressSize = sizeof(struct in6_addr),
};
/* Helper function for inet_pton() for IPv4 addresses. */
« no previous file with comments | « native_client_sdk/src/libraries/nacl_io/syscalls/inet_ntop.cc ('k') | native_client_sdk/src/tests/nacl_io_test/socket_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698