GVCP: do not try to append register value to info column when READREG_ACK has an...
authorPascal Quantin <pascal.quantin@gmail.com>
Tue, 27 Oct 2015 14:42:45 +0000 (15:42 +0100)
committerPascal Quantin <pascal.quantin@gmail.com>
Tue, 27 Oct 2015 16:54:36 +0000 (16:54 +0000)
Bug: 11639
Change-Id: I1389b74092138e3b28cf4f0dd2d2c8967ec8ba12
Reviewed-on: https://code.wireshark.org/review/11310
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
epan/dissectors/packet-gvcp.c

index 00147571e95cca112c7ca76cafef0c3f802b91ba..02d557a57ce2acd17fcb0cab4505ddcbe58f786f 100644 (file)
@@ -1955,7 +1955,14 @@ static void dissect_readreg_ack(proto_tree *gvcp_telegram_tree, tvbuff_t *tvb, p
                                address_string = get_register_name_from_address(*((guint32*)wmem_array_index(gvcp_trans->addr_list, 0)), &is_custom_register);
                        }
 
-                       col_append_fstr(pinfo->cinfo, COL_INFO, "%s Value=0x%08X", address_string, tvb_get_ntohl(tvb, offset));
+                       if (num_registers)
+                       {
+                               col_append_fstr(pinfo->cinfo, COL_INFO, "%s Value=0x%08X", address_string, tvb_get_ntohl(tvb, offset));
+                       }
+                       else
+                       {
+                               col_append_fstr(pinfo->cinfo, COL_INFO, "%s", address_string);
+                       }
                }
        }