summaryrefslogtreecommitdiff
path: root/epan/tvbuff.c
diff options
context:
space:
mode:
authorAnders Broman <anders.broman@ericsson.com>2011-09-26 18:56:27 +0000
committerAnders Broman <anders.broman@ericsson.com>2011-09-26 18:56:27 +0000
commitf54cc3fcb7a54c2cc8da5e130b5b1ce1b251b863 (patch)
treeea868cbf45426937e6dca534af2834a6efb7373b /epan/tvbuff.c
parent94f51b09ccee9044e67a0fbf0c45bb60da82c569 (diff)
downloadwireshark-f54cc3fcb7a54c2cc8da5e130b5b1ce1b251b863.tar.gz
Another bug fix from Pascal.
svn path=/trunk/; revision=39155
Diffstat (limited to 'epan/tvbuff.c')
-rw-r--r--epan/tvbuff.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/epan/tvbuff.c b/epan/tvbuff.c
index 2a5bed0215..a34bcec9a0 100644
--- a/epan/tvbuff.c
+++ b/epan/tvbuff.c
@@ -151,7 +151,7 @@ tvb_new_octet_aligned(tvbuff_t *tvb, guint32 bit_offset, gint32 no_of_bits)
}
/* already aligned -> shortcut */
- if (left == 0) {
+ if ((left == 0) && (remaining_bits == 0)) {
return tvb_new_subset(tvb, byte_offset, datalen, -1);
}