summaryrefslogtreecommitdiff
path: root/ratox.c
diff options
context:
space:
mode:
authorsin <sin@2f30.org>2014-10-01 19:08:28 +0100
committersin <sin@2f30.org>2014-10-01 19:09:35 +0100
commit30eb05ef9c7a1a8bea4bc1c88abd154d11421db2 (patch)
tree9582f086161d288cea774560f8932c4b880448b8 /ratox.c
parent07b2fa713191fd705094f05d4aba21794a012f3f (diff)
Use strtoul() instead of strtol()
Diffstat (limited to 'ratox.c')
-rw-r--r--ratox.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ratox.c b/ratox.c
index 8783f13..da89a06 100644
--- a/ratox.c
+++ b/ratox.c
@@ -1345,7 +1345,7 @@ setnospam(void *data)
{
uint8_t nospam[2 * sizeof(uint32_t) + 1];
uint8_t address[TOX_FRIEND_ADDRESS_SIZE];
- int32_t nsval;
+ uint32_t nsval;
ssize_t n, i;
n = fiforead(gslots[NOSPAM].dirfd, &gslots[NOSPAM].fd[IN], gfiles[IN],
@@ -1363,7 +1363,7 @@ setnospam(void *data)
}
}
- nsval = strtol((char *)nospam, NULL, 16);
+ nsval = strtoul((char *)nospam, NULL, 16);
tox_set_nospam(tox, nsval);
datasave();
printout("Nospam > %08X\n", nsval);