From 21a422463ef37e09bffb6dafbc9e16543e38d151 Mon Sep 17 00:00:00 2001 From: Jeff Morriss Date: Mon, 13 Feb 2012 03:14:46 +0000 Subject: If WIRESHARK_ABORT_ON_DISSECTOR_BUG is set (in the environment) and we put more than MAX_TREE_ITEMS in the tree, abort() out rather than throwing an exception. svn path=/trunk/; revision=41009 --- epan/proto.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'epan/proto.c') diff --git a/epan/proto.c b/epan/proto.c index 7c3a2148c4..777e08c224 100644 --- a/epan/proto.c +++ b/epan/proto.c @@ -107,6 +107,8 @@ wrs_count_bitshift(const guint32 bitmask) return(NULL); \ PTREE_DATA(tree)->count++; \ if (PTREE_DATA(tree)->count > MAX_TREE_ITEMS) { \ + if (getenv("WIRESHARK_ABORT_ON_DISSECTOR_BUG") != NULL) \ + abort(); \ /* Let the exception handler add items to the tree */ \ PTREE_DATA(tree)->count = 0; \ THROW_MESSAGE(DissectorError, \ -- cgit v1.2.1