Do not try to set IR header length when the profile is unknown

svn path=/trunk/; revision=44700
This commit is contained in:
Pascal Quantin 2012-08-30 12:08:53 +00:00
parent 1ccee24ec5
commit 0e79405e0d
1 changed files with 5 additions and 3 deletions

View File

@ -1414,8 +1414,10 @@ dissect_rohc_ir_packet(tvbuff_t *tvb, proto_tree *tree, packet_info *pinfo,
break;
}
/* Set length of IR header */
proto_item_set_len(ir_item, offset-ir_item_start);
if (offset != -1) {
/* Set length of IR header */
proto_item_set_len(ir_item, offset-ir_item_start);
}
return offset;
}
@ -1737,7 +1739,7 @@ start_over:
col_append_str(pinfo->cinfo, COL_INFO, "IR packet");
offset = dissect_rohc_ir_packet(tvb, rohc_tree, pinfo, offset, cid, is_add_cid, p_rohc_info);
if(offset == -1){
/* Could not pare header */
/* Could not parse header */
return;
}
/*proto_tree_add_text(rohc_tree, tvb, offset, -1, "Data");*/