Commit c1ff5d6b authored by Nick Galbreath's avatar Nick Galbreath Committed by Ilya Lipnitskiy

protobuf-c/protobuf-c.c: prevent possible overflow on 64-bit systems

(fixes #106)
parent b915eed3
......@@ -2248,7 +2248,7 @@ protobuf_c_message_init_generic (const ProtobufCMessageDescriptor *desc,
choose the number so that we would overflow if we needed
a slab larger than provided. */
#define MAX_SCANNED_MEMBER_SLAB \
(sizeof(void*)*8 - 1 \
(sizeof(unsigned int)*8 - 1 \
- BOUND_SIZEOF_SCANNED_MEMBER_LOG2 \
- FIRST_SCANNED_MEMBER_SLAB_SIZE_LOG2)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment