Convert sizeof foo to sizeof(foo).
[oweals/tinc.git] / src / utils.c
index 555ea50d7461b38c9a000bfe559e10ed275e0ccf..656f1ea41ac38b46f243a6c67f3658327408b359 100644 (file)
@@ -73,8 +73,8 @@ const char *winerror(int err) {
 
 unsigned int bitfield_to_int(const void *bitfield, size_t size) {
        unsigned int value = 0;
-       if(size > sizeof value)
-               size = sizeof value;
+       if(size > sizeof(value))
+               size = sizeof(value);
        memcpy(&value, bitfield, size);
        return value;
 }