diff options
author | Guy Harris <guy@alum.mit.edu> | 2014-10-15 16:45:51 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2014-10-15 23:46:41 +0000 |
commit | f518089709feba05fe8acfab76be5afc8bd97021 (patch) | |
tree | c9a284723a3a575f507b326c67b2cd3b74921668 /ringbuffer.h | |
parent | 371e4ae1c787bfbfd292fbf2474624241ea942f9 (diff) | |
download | wireshark-f518089709feba05fe8acfab76be5afc8bd97021.tar.gz |
Clean up the read routines.
The block read routines don't need to return a "bytes read" amount any
more.
Have pcapng_read_block() just return an indication:
PCAPNG_BLOCK_OK - the read succeeded;
PCAPNG_BLOCK_NOT_SHB - the read failed in a fashion that
indicates that we might just not be reading a pcap-ng file;
PCAPNG_BLOCK_ERROR - the read failed in some other fashion
(i.e., we already have concluded that the file is a pcap-ng
file, or we got an I/O error).
In the cases where it needs to know whether it's reading the first block
for an open, have it check the shb_read flag, rather than being passed a
separate Boolean argument.
This means that pcapng_read_section_header_block() should return such an
indication as well.
Make the other block-reading routines return a Boolean success/failure
indication.
Change-Id: Id371457018a008ece9058d6042da44d631e51889
Reviewed-on: https://code.wireshark.org/review/4710
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'ringbuffer.h')
0 files changed, 0 insertions, 0 deletions