Huge thanks to our Platinum Members Endace and LiveAction,
and our Silver Member Veeam, for supporting the Wireshark Foundation and project.

Wireshark-bugs: [Wireshark-bugs] [Bug 8841] dissect_per_normally_small_nonnegative_whole_number

Date: Fri, 05 Jul 2013 09:37:52 +0000

Comment # 6 on bug 8841 from
(In reply to comment #5)
> This code you copy pasted does exactly what is described in X.691 chapters
> 10.9.3.6 and 10.9.3.7 and put in length variable the content of the "length"
> fields as drawn in the spec.

so, dissect_per_normally_small_nonnegative_whole_number has a bug,right?

because function int dissect_per_length_determinant(******, length) 's
parameter length is lenght not value.

do you agree this is a bug? 
thank you very much
///////////////////////////////////////////////////////////////////////
static guint32
dissect_per_normally_small_nonnegative_whole_number(tvbuff_t *tvb, guint32
offset, asn1_ctx_t *actx, proto_tree *tree, int hf_index, guint32 *length)
{


(1)--->    if(!small_number)//
    {

       offset=dissect_per_boolean(tvb, offset, actx, tree, -1, 
     *length<<=1;
     if (length_bit) 
(value)     {
(2)------>   *length|=1;--->it is value not length
     }

    }

(length)    /* 10.6.2 */
(3)------> offset=dissect_per_length_determinant( "..." ,hf_index, 
                                                 length -->it is length not
value)

    return offset;
}


You are receiving this mail because:
  • You are watching all bug changes.