Blame SOURCES/wireshark-1.10.0-CVE-2013-3557.patch

ead5f6
diff --git a/epan/dissectors/packet-ber.c b/epan/dissectors/packet-ber.c
ead5f6
index 7dcfd42..adf01bd 100644
ead5f6
--- a/epan/dissectors/packet-ber.c
ead5f6
+++ b/epan/dissectors/packet-ber.c
ead5f6
@@ -3503,6 +3503,10 @@ printf("CHOICE dissect_ber_old_choice(%s) entered len:%d\n", name, tvb_length_re
ead5f6
 #endif
ead5f6
     start_offset = offset;
ead5f6
 
ead5f6
+    if (branch_taken) {
ead5f6
+        *branch_taken = -1;
ead5f6
+    }
ead5f6
+
ead5f6
     if (tvb_length_remaining(tvb, offset) == 0) {
ead5f6
         item = proto_tree_add_string_format(
ead5f6
             parent_tree, hf_ber_error, tvb, offset, 0, "empty_choice",
ead5f6
@@ -3545,9 +3549,6 @@ printf("CHOICE dissect_ber_old_choice(%s) entered len:%d\n", name, tvb_length_re
ead5f6
     /* loop over all entries until we find the right choice or
ead5f6
        run out of entries */
ead5f6
     ch = choice;
ead5f6
-    if (branch_taken) {
ead5f6
-        *branch_taken = -1;
ead5f6
-    }
ead5f6
     first_pass = TRUE;
ead5f6
     while (ch->func || first_pass) {
ead5f6
         if (branch_taken) {