Text   |  XML   |  ReML   |   Visible Warnings:

Uninitialized Variable  at strutil.c:396

No properties have been set. | edit properties
Jump to warning location ↓ warning details...
Show Events | Options

udvm_state_access

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/sigcomp_state_hdlr.c)expand/collapse
Show more  
 680  int udvm_state_access(tvbuff_t *tvb, proto_tree *tree,guint8 *buff,guint16 p_id_start, guint16 p_id_length, guint16 state_begin, guint16 *state_length,  
 681                                             guint16 *state_address, guint16 *state_instruction,  
 682                                             gint hf_id)
 683  {
 684          int                     result_code = 0;
 685          guint32         n;
 686          guint16         k;
 687          guint16         byte_copy_right;
 688          guint16         byte_copy_left;
 689          char            partial_state[STATE_BUFFER_SIZE]; /* Size is 6 - 20 */
 690          guint8          *state_buff;
 691          gchar           *partial_state_str;
 692   
 693          /*  
 694           * Perform initial checks on validity of data 
 695           * RFC 3320 :
 696           * 9.4.5.  STATE-ACCESS
 697           * :
 698           * Decompression failure occurs if partial_identifier_length does not 
 699           * lie between 6 and 20 inclusive.  Decompression failure also occurs if
 700           * no state item matching the partial state identifier can be found, if 
 701           * more than one state item matches the partial identifier, or if
 702           * partial_identifier_length is less than the minimum_access_length of 
 703           * the matched state item. Otherwise, a state item is returned from the 
 704           * state handler.
 705           */
 706   
 707          if (( p_id_length < STATE_MIN_ACCESS_LEN ) || ( p_id_length > STATE_BUFFER_SIZE )){
 708                  result_code = 1;
 709                  return result_code;
 710          }
 711   
 712          n = 0;
 713          while ( n < p_id_length && n < STATE_BUFFER_SIZE && p_id_start + n < UDVM_MEMORY_SIZE ){
 714                  partial_state[n] = buff[p_id_start + n];
 715                  n++;
 716          }
 717[+]         partial_state_str = bytes_to_str(partial_state, p_id_length);
expand/collapse

bytes_to_str

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/strutil.c)expand/collapse
Show more  
 378  gchar *
 379  bytes_to_str(const guint8 *bd, int bd_len) {
 380[+]   return bytes_to_str_punct(bd,bd_len,'\0');
expand/collapse

bytes_to_str_punct

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/strutil.c)expand/collapse
Show more  
 386  gchar *
 387  bytes_to_str_punct(const guint8 *bd, int bd_len, gchar punct) {
 388    gchar        *cur;
 389    gchar        *p;
 390    int           len;
 391   
 392    cur=ep_alloc(MAX_BYTE_STR_LEN+3+1);
 393    p = cur;
 394    len = MAX_BYTE_STR_LEN;
 395    while (bd_len > 0 && len > 0) {
 396      *p++ = hex[(*bd) >> 4];
Show more  
Show more  
Show more  




Change Warning 2949.31070 : Uninitialized Variable

Priority:
State:
Finding:
Owner:
Note: