diff options
author | Guy Harris <guy@alum.mit.edu> | 2003-12-23 21:22:00 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2003-12-23 21:22:00 +0000 |
commit | 821baa3d48ae58afb1da20e5f4f7e0699c1520b6 (patch) | |
tree | 2766be43df63431fc4fe45f4591cd8a8b16f57fd /packet-beep.c | |
parent | 8afbfc0c6097596b50d41c849210337bd9c41ccc (diff) | |
download | wireshark-821baa3d48ae58afb1da20e5f4f7e0699c1520b6.tar.gz wireshark-821baa3d48ae58afb1da20e5f4f7e0699c1520b6.tar.bz2 wireshark-821baa3d48ae58afb1da20e5f4f7e0699c1520b6.zip |
Have "tvb_ensure_length_remaining()" throw the appropriate exception if
there's no data remaining - its callers largely depend on it doing so.
That means that the BEEP dissector doesn't have to check for it
returning 0.
svn path=/trunk/; revision=9433
Diffstat (limited to 'packet-beep.c')
-rw-r--r-- | packet-beep.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/packet-beep.c b/packet-beep.c index ece630ccde..8be72383fd 100644 --- a/packet-beep.c +++ b/packet-beep.c @@ -1,7 +1,7 @@ /* packet-beep.c * Routines for BEEP packet disassembly * - * $Id: packet-beep.c,v 1.13 2003/07/25 04:17:36 gram Exp $ + * $Id: packet-beep.c,v 1.14 2003/12/23 21:18:57 guy Exp $ * * Copyright (c) 2000 by Richard Sharpe <rsharpe@ns.aus.com> * Modified 2001 Darren New <dnew@invisible.net> for BEEP. @@ -389,9 +389,6 @@ static int header_len(tvbuff_t *tvb, int offset) while (1) { - if (tvb_ensure_length_remaining(tvb, offset + i) < 1) - return i; /* Not enough characters left ... */ - if ((sc = tvb_get_guint8(tvb, offset + i)) == 0x0d && tvb_get_guint8(tvb, offset + i + 1) == 0x0a) return i; /* Done here ... */ |