diff options
author | Niels Möller <nisse@lysator.liu.se> | 2013-02-20 11:22:00 +0100 |
---|---|---|
committer | Niels Möller <nisse@lysator.liu.se> | 2013-02-20 11:22:00 +0100 |
commit | aaf431459847561bc8df7e31bfb62fe95cfc3382 (patch) | |
tree | 39865ad23238b0a8c633b382e02466eb335cc503 /nettle-internal.h | |
parent | 8cf51d223d4a4dc19b840e9fff74379e762d5097 (diff) | |
download | nettle-aaf431459847561bc8df7e31bfb62fe95cfc3382.tar.gz |
Fixed TMP_ALLOC, was missing parentheses.
Diffstat (limited to 'nettle-internal.h')
-rw-r--r-- | nettle-internal.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/nettle-internal.h b/nettle-internal.h index e85e3c5f..3b7f771d 100644 --- a/nettle-internal.h +++ b/nettle-internal.h @@ -36,11 +36,11 @@ #if HAVE_ALLOCA # define TMP_DECL(name, type, max) type *name -# define TMP_ALLOC(name, size) (name = alloca(sizeof (*name) * size)) +# define TMP_ALLOC(name, size) (name = alloca(sizeof (*name) * (size))) #else /* !HAVE_ALLOCA */ # define TMP_DECL(name, type, max) type name[max] # define TMP_ALLOC(name, size) \ -do { if (size > (sizeof(name) / sizeof(name[0]))) abort(); } while (0) + do { if ((size) > (sizeof(name) / sizeof(name[0]))) abort(); } while (0) #endif /* Arbitrary limits which apply to systems that don't have alloca */ |