Text   |  XML   |  ReML   |   Visible Warnings:

Null Pointer Dereference  at proto.c:1328

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

dissect_homeplug

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/dissectors/packet-homeplug.c)expand/collapse
Show more  
 1324  dissect_homeplug(tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree)
 1325  {
 1326    proto_item * it= NULL;
 1327    proto_tree * homeplug_tree= NULL;
 1328    ptvcursor_t * cursor= NULL;
 1329   
 1330[+]   if (check_col(pinfo->cinfo, COL_PROTOCOL))
 1331      col_set_str(pinfo->cinfo, COL_PROTOCOL, "HomePlug");
 1332    /* Clear out stuff in the info column */
 1333[+]   if (check_col(pinfo->cinfo, COL_INFO)) {
 1334      col_clear(pinfo->cinfo, COL_INFO);
 1335      col_set_str(pinfo->cinfo, COL_INFO, "MAC Management");
 1336    }
 1337   
 1338    homeplug_offset = 0;
 1339   
 1340    if (tree) {
 1341      it = proto_tree_add_item(tree, proto_homeplug, tvb, homeplug_offset, -1, FALSE);
 1342      homeplug_tree = proto_item_add_subtree(it, ett_homeplug);
 1343      cursor = ptvcursor_new(homeplug_tree, tvb, 0);
 1344    }
 1345   
 1346    /*  We do not have enough data to read mctrl field stop the dissection */
 1347[+]   if (check_tvb_length(cursor, HOMEPLUG_MCTRL_LEN) != TVB_LEN_SHORTEST) {
 1348   
 1349      dissect_homeplug_mctrl(cursor);
 1350   
 1351      /** homeplug_ne indicates the number of MME entries. This field is fetched
 1352       *  from MCTRL.  
 1353       */
 1354[+]     if ((homeplug_ne > 0) && check_col(pinfo->cinfo, COL_INFO)) {
 1355        col_clear(pinfo->cinfo, COL_INFO);
 1356      }
 1357      for (; homeplug_ne > 0; homeplug_ne--) {
 1358   
 1359        /* Check we have enough data in tvb to read MEHDR */
 1360[+]       if (check_tvb_length(cursor, HOMEPLUG_MEHDR_LEN) == TVB_LEN_SHORTEST)
 1361          break;
 1362        dissect_homeplug_mehdr(cursor);
 1363   
 1364        /* Check we have enough data in tvb to read MELEN */
 1365[+]       if (check_tvb_length(cursor, HOMEPLUG_MELEN_LEN) == TVB_LEN_SHORTEST)
 1366          break;
 1367        dissect_homeplug_melen(cursor);
 1368   
 1369[+]       dissect_homeplug_mme(cursor, pinfo);
expand/collapse

dissect_homeplug_mme

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/dissectors/packet-homeplug.c)expand/collapse
Show more  
 1264  static void dissect_homeplug_mme(ptvcursor_t * cursor, packet_info * pinfo)
 1265  {
 1266[+]   if (check_col(pinfo->cinfo, COL_INFO)) {
 1267      col_append_sep_str(pinfo->cinfo, COL_INFO, ", ",
 1268          val_to_str(homeplug_metype, homeplug_metype_vals, "Unknown 0x%x"));
 1269    }
 1270   
 1271    switch(homeplug_metype) {
 1272      case HOMEPLUG_MME_RCE:
 1273        dissect_homeplug_rce(cursor);
 1274        break;
 1275      case HOMEPLUG_MME_CER:
 1276        dissect_homeplug_cer(cursor);
 1277        break;
 1278      case HOMEPLUG_MME_VS:
 1279        dissect_homeplug_vs(cursor);
 1280        break;
 1281      case HOMEPLUG_MME_SNK:
 1282
1291
Show [ Lines 1282 to 1291 omitted. ]
 1292        break;
 1293      case HOMEPLUG_MME_NS:
 1294        dissect_homeplug_ns(cursor, pinfo);
 1295        break;
 1296      case HOMEPLUG_MME_BC:
 1297        dissect_homeplug_bc(cursor, pinfo);
 1298        break;
 1299      case HOMEPLUG_MME_STC:
 1300        dissect_homeplug_stc(cursor);
 1301        break;
 1302      default:
 1303[+]       dissect_homeplug_unknown(cursor);
expand/collapse

dissect_homeplug_unknown

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/dissectors/packet-homeplug.c)expand/collapse
Show more  
 1259  static void dissect_homeplug_unknown(ptvcursor_t * cursor)
 1260  {
 1261[+]   ptvcursor_add(cursor, hf_homeplug_data, homeplug_melen, FALSE);
expand/collapse

ptvcursor_add

(/home/sate/Testcases/c/cve/wireshark-1.2.0/epan/proto.c)expand/collapse
Show more  
 1318  proto_item*
 1319  ptvcursor_add(ptvcursor_t *ptvc, int hfindex, gint length,
 1320                gboolean little_endian)
 1321  {
 1322          field_info              *new_fi;
 1323          header_field_info       *hfinfo;
 1324          gint                    item_length;
 1325          guint32                 n;
 1326          int                     offset;
 1327   
 1328          offset = ptvc->offset;
Show more  
Show more  
Show more  
Show more  




Change Warning 2637.34867 : Null Pointer Dereference

Priority:
State:
Finding:
Owner:
Note: