aboutsummaryrefslogtreecommitdiffstats
path: root/src/libmdsserver/util.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@operamail.com>2014-08-12 15:39:39 +0200
committerMattias Andrée <maandree@operamail.com>2014-08-12 15:39:39 +0200
commit856c92de0cfccee39750fda1d04d410fdb06bbe2 (patch)
tree43b2ec983835e15d6c785687fcbd75c27a45d988 /src/libmdsserver/util.c
parentmissed explicit cast (diff)
downloadmds-856c92de0cfccee39750fda1d04d410fdb06bbe2.tar.gz
mds-856c92de0cfccee39750fda1d04d410fdb06bbe2.tar.bz2
mds-856c92de0cfccee39750fda1d04d410fdb06bbe2.tar.xz
macros for ato* with cast
Signed-off-by: Mattias Andrée <maandree@operamail.com>
Diffstat (limited to '')
-rw-r--r--src/libmdsserver/util.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/libmdsserver/util.c b/src/libmdsserver/util.c
index 469b616..7047d9b 100644
--- a/src/libmdsserver/util.c
+++ b/src/libmdsserver/util.c
@@ -57,9 +57,8 @@ uint64_t parse_client_id(const char* str)
strcpy(client_high = client_words, str);
client_low = rawmemchr(client_words, ':');
*client_low++ = '\0';
- client = (uint64_t)atoll(client_high);
- client <<= 32;
- client |= (uint64_t)atoll(client_low);
+ client = atou64(client_high) << 32;
+ client |= atou64(client_low);
return client;
}