summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ratox.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ratox.c b/ratox.c
index 71d8df8..72a66b5 100644
--- a/ratox.c
+++ b/ratox.c
@@ -1098,7 +1098,7 @@ localinit(void)
/* Dump Nospam */
ftruncate(gslots[NOSPAM].fd[OUT], 0);
- dprintf(gslots[NOSPAM].fd[OUT], "%08X\n", tox_self_get_nospam(tox));
+ dprintf(gslots[NOSPAM].fd[OUT], "%08X\n", ntohl(tox_self_get_nospam(tox)));
return 0;
}
@@ -1505,8 +1505,8 @@ setnospam(void *data)
}
}
- nsval = htonl(strtoul((char *)nospam, NULL, 16));
- tox_self_set_nospam(tox, nsval);
+ nsval = strtoul((char *)nospam, NULL, 16);
+ tox_self_set_nospam(tox, htonl(nsval));
datasave();
logmsg("Nospam > %08X\n", nsval);
ftruncate(gslots[NOSPAM].fd[OUT], 0);