diff options
| author | Garrett D'Amore <garrett@damore.org> | 2018-08-30 11:08:06 -0700 |
|---|---|---|
| committer | Garrett D'Amore <garrett@damore.org> | 2018-08-30 15:28:38 -0700 |
| commit | 629002efac8085a9c6321a15b43a47a43ca0e084 (patch) | |
| tree | 8d540d491a6583405e625dd11e12f993457837a7 /src/transport | |
| parent | e7e980c228c76e108bbc4812f40645d93626757f (diff) | |
| download | nng-629002efac8085a9c6321a15b43a47a43ca0e084.tar.gz nng-629002efac8085a9c6321a15b43a47a43ca0e084.tar.bz2 nng-629002efac8085a9c6321a15b43a47a43ca0e084.zip | |
fixes #686 strtoull() not present on Windows
This both makes new functions available to the core,
and addresses a bug which would have prevented building the
ZeroTier transport on Windows.
Diffstat (limited to 'src/transport')
| -rw-r--r-- | src/transport/zerotier/zerotier.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/transport/zerotier/zerotier.c b/src/transport/zerotier/zerotier.c index 0b0303d9..95fedc0d 100644 --- a/src/transport/zerotier/zerotier.c +++ b/src/transport/zerotier/zerotier.c @@ -1529,14 +1529,12 @@ zt_walk_moons(const char *path, void *arg) { zt_node * ztn = arg; const char *bn = nni_file_basename(path); - char * ep; uint64_t moonid; if (strncmp(bn, "moon.", 5) != 0) { return (NNI_FILE_WALK_CONTINUE); } - moonid = strtoull(bn + 5, &ep, 16); - if (*ep == '\0') { + if (nni_strtox64(bn + 5, &moonid) == 0) { ZT_Node_orbit(ztn->zn_znode, NULL, moonid, 0); } return (NNI_FILE_WALK_CONTINUE); |
