beter displaying of true/false strings in dissect_ber_bitstring()
authorkukosa <kukosa@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 1 Jul 2005 13:48:52 +0000 (13:48 +0000)
committerkukosa <kukosa@f5534014-38df-0310-8fa8-9805f1628bb7>
Fri, 1 Jul 2005 13:48:52 +0000 (13:48 +0000)
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@14828 f5534014-38df-0310-8fa8-9805f1628bb7

epan/dissectors/packet-ber.c

index bf01d60fe757347677d6c4f9e1356d015b3d64fc..222e19aade0e14f5089d300cc4af8a75a1f54bf4 100644 (file)
@@ -1800,15 +1800,18 @@ int dissect_ber_bitstring(gboolean implicit_tag, packet_info *pinfo, proto_tree
                                proto_tree_add_boolean(tree, *(nb->p_id), tvb, offset + len, 0, 0x00);
                        }
                        if (val) {
-                               if (item && nb->tstr)
+                               if (item && nb->tstr) {
                                        proto_item_append_text(item, "%s%s", sep, nb->tstr);
+                                       term = TRUE;
+                               }
                        } else {
-                               if (item && nb->fstr)
+                               if (item && nb->fstr) {
                                        proto_item_append_text(item, "%s%s", sep, nb->fstr);
+                                       term = TRUE;
+                               }
                        }
                        nb++;
-                       sep = ", ";
-                       term = TRUE;
+                       if (term) sep = ", ";
                }
                if (term)
                        proto_item_append_text(item, ")");