aboutsummaryrefslogtreecommitdiffstats
path: root/ringbuffer.c
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2017-03-09 20:20:20 -0800
committerGuy Harris <guy@alum.mit.edu>2017-03-10 04:21:05 +0000
commitc2e74c5fc2cf9c0f6d85c2e6ce5bcb0cfb777b26 (patch)
treec73c286aebf4afcb15507393ac7c34d73846a541 /ringbuffer.c
parentfe285c640b6279fdb9920bb79b0494ac87cb0e32 (diff)
Don't cast to a too-large size.
The maximum record length is 255*128 + 127 = 32767; that fits in a guint32, which is large enough to support the biggest packet we'd ever support without stretching several size values to 64 bits. It's not a size of an object in memory, so it doesn't have to be a size_t, and a size_t could be too large to fit in the record sizes we're using. Just cast to guint32. Change-Id: Ie664fda3ce9945893fd992bbb9a81a5d632a3fcb Reviewed-on: https://code.wireshark.org/review/20479 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'ringbuffer.c')
0 files changed, 0 insertions, 0 deletions