URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=fbecf1c32f2eaeb1587ec4be8b84eaa40c7f84e8
Submitter: "Peter Wu <peter@xxxxxxxxxxxxx>"
Changed: branch: master-2.6
Repository: wireshark
Commits:
fbecf1c by Peter Wu (peter@xxxxxxxxxxxxx):
DCERPC: simplify pointer list tracking
Observe that the "current_depth" and "len_ndr_pointer_list" just track
the length of the current singly linked list in order to insert (append)
or remove [the last] element (a linked list of lists and a linked list
of pointers respectively). Replace these callers by equivalents that do
not require explicit length tracking, internally they both have to do a
O(n) lookup anyway.
There used to be a case where "current_depth" could run out-of-sync, no
longer tracking the actual list length: when the callback (tnpd->fnct or
tnpd->callback) triggers an exception. I believe this was unintentional.
No functional change intended, but this should make further changes to
the data structures easier.
Change-Id: I3cb13aba22caa87dc7baba411cf34f47792f7bb7
Ping-Bug: 14735
Fixes: v2.5.0rc0-292-g6bd87bdd5d ("dcerpc: improve greatly the speed of processing of DCERPC packets")
Reviewed-on: https://code.wireshark.org/review/30114
Petri-Dish: Peter Wu <peter@xxxxxxxxxxxxx>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@xxxxxxxxx>
(cherry picked from commit 0e0e56d05bfc34026a9923f847b8c8d53136256f)
Reviewed-on: https://code.wireshark.org/review/30154
Reviewed-by: Peter Wu <peter@xxxxxxxxxxxxx>
Actions performed:
from f489f8f tvbuff_composite: fix buffer overflow due to wrong offset adjustment
add fbecf1c DCERPC: simplify pointer list tracking
Summary of changes:
epan/dissectors/packet-dcerpc.c | 51 ++++++++++++++++-------------------------
1 file changed, 20 insertions(+), 31 deletions(-)