Fix for bug 1272.
authorjake <jake@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 22 Dec 2006 14:48:51 +0000 (14:48 +0000)
committerjake <jake@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 22 Dec 2006 14:48:51 +0000 (14:48 +0000)
Check length remaining before aligning.

git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@20198 f5534014-38df-0310-8fa8-9805f1628bb7

epan/dissectors/packet-giop.c

index 597fc3ff2f4a3c1dd4b591697d0822e1303fa796..435205fa335e614b624789c8b9eefc1f605afc6b 100644 (file)
@@ -3586,7 +3586,10 @@ dissect_giop_request_1_2 (tvbuff_t * tvb, packet_info * pinfo,
    * GIOP octet stream start.
    */
 
-  set_new_alignment(&offset, GIOP_HEADER_SIZE, 8);
+  if (tvb_reported_length_remaining(tvb, offset) > 0)
+  {
+    set_new_alignment(&offset, GIOP_HEADER_SIZE, 8);
+  }
 
   /*
    * Save FN,reqid,and operation for later. Add sub_handle later.