aboutsummaryrefslogtreecommitdiffstats
path: root/ui/summary.c
AgeCommit message (Collapse)AuthorFilesLines
2023-02-06Do not require using wsgcrypt.hJoão Valverde1-1/+1
The reason to use wsgcrypt.h was to wrap it around DIAG_OFF() macros and that should no longer be necessary.
2021-12-19Replace g_snprintf() with snprintf()João Valverde1-1/+1
Use macros from inttypes.h with format strings.
2021-07-14wiretap: clean up option definitions a bit.Guy Harris1-1/+1
Spell out "DESCRIPTION" for the IDB description option, as it's spelled out in the pcapng spec. Put the #defines for various options in the same order as the block types for them are in the pcapng spec.
2021-04-30Cast away the return value of g_strlcpy() and g_strlcat().Guy Harris1-3/+3
Most of the time, the return value tells us nothing useful, as we've already decided that we're perfectly willing to live with string truncation. Hopefully this keeps Coverity from whining that those routines could return an error code (NARRATOR: They don't) and thus that we're ignoring the possibility of failure (as indicated, we've already decided that we can live with string truncation, so truncation is *NOT* a failure).
2021-04-20Remove unneeded modelines in ui.Gerald Combs1-13/+0
Remove the editor modeline blocks from the source files in ui that use 4 space indentation by running perl -i -p0e 's{ \n+ /[ *\n]+ editor \s+ modelines .* shiftwidth= .* \*/ \s+ } {\n}gsix' $( ag -l shiftwidth=4 $( ag -g '\.(c|cpp|h|m|mm)') ) This gives us one source of indentation truth for these files, and it *shouldn't* affect anyone since - These files match the default in our top-level .editorconfig. - The one notable editor that's likely to be used on these files and *doesn't* support EditorConfig (Qt Creator) defaults to 4 space indentation.
2021-03-15Remove unnecessary inclues of wiretap/pcapng.h.Guy Harris1-1/+0
2021-03-01Make ui/*.[ch] indentation consistent.Gerald Combs1-196/+196
Switch ui/clopts_common.c, ui/filter_files.[ch], and ui/summary.[ch] to 4 space indentation. This brings them in line with all of the other files in that directory and with ui/qt. Fix the modelines in ui/qt/models/filter_list_model.cpp.
2021-02-01wiretap: redo the way we handle if_filter IDB options.Guy Harris1-3/+8
Change the data structure for that option to have a type field, indicating that it's either a pcap filter string or a BPF program, followed by a union with a string-pointer member for pcap filter strings and an instruction-count-and-pointer-to-instructions structure for BPF programs. Have routines to add, set, and fetch that option that handle that structure; discard the "generic structured option" routines. That means there's more type checking possible at compile time. Add more code to handle BPF programs. When writing pcapng files, check, both for that option and for string options, whether the option length is too big for the data to fit in a pcapng option, and don't write it if it is. (XXX - truncate the data? Report an error?)
2021-01-30Refer to options whose data isn't a simple data type as "structured".Guy Harris1-1/+1
"Custom", as in "requires custom handling of the option data, collides with "custom", as in pcapng custom options.
2019-07-26HTTPS (almost) everywhere.Guy Harris1-1/+1
Change all wireshark.org URLs to use https. Fix some broken links while we're at it. Change-Id: I161bf8eeca43b8027605acea666032da86f5ea1c Reviewed-on: https://code.wireshark.org/review/34089 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-12-27Try to squeeze some bytes out of the frame_data structure.Guy Harris1-6/+6
Make the time stamp precision a 4-bit bitfield, so, when combined with the other bitfields, we have 32 bits. That means we put the flags at the same structure level as the time stamp precision, so they can be combined; that gets rid of an extra "flags." for references to the flags. Put the two pointers next to each other, and after a multiple of 8 bytes worth of other fields, so that there's no padding before or between them. It's still not down to 64 bytes, which is the next lower power of 2, so there's more work to do. Change-Id: I6f3e9d9f6f48137bbee8f100c152d2c42adb8fbe Reviewed-on: https://code.wireshark.org/review/31213 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-11-16Use an enum for compression types in various interfaces.Guy Harris1-1/+1
This: 1) means that we don't have to flag the compression argument with a comment to indicate what it means (FALSE doesn't obviously say "not compressed", WTAP_UNCOMPRESSED does); 2) leaves space in the interfaces in question for additional compression types. (No, this is not part 1 of an implementation of additional compression types, it's just an API cleanup. Implementing additional compression types involves significant work in libwiretap, as well as UI changes to replace "compress the file" checkboxes with something to indicate *how* to compress the file, or to always use some other form of compression). Change-Id: I1d23dc720be10158e6b34f97baa247ba8a537abf Reviewed-on: https://code.wireshark.org/review/30660 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-11-07Qt: Add file hashes to capture file properties dialogJaap Keuter1-0/+48
Like capinfos provide file hashes in the capture file properties dialog. Change-Id: Ia9f1b05f61abd239d81b7061bbba1e53c01f28be Signed-off-by: Jaap Keuter <jaap.keuter@xs4all.nl> Reviewed-on: https://code.wireshark.org/review/30524 Tested-by: Petri Dish Buildbot Reviewed-by: Stig Bjørlykke <stig@bjorlykke.org> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-08-11Give a structure a better name.Guy Harris1-3/+3
It's not a set of command-line options, it's information that's used when showing summary information about the interface. Change-Id: Ie1c3d998a3cc7cd8b54945186098ebae726cef11 Reviewed-on: https://code.wireshark.org/review/29070 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-02-08replace SPDX identifier GPL-2.0+ with GPL-2.0-or-later.Dario Lombardo1-1/+1
The first is deprecated, as per https://spdx.org/licenses/. Change-Id: I8e21e1d32d09b8b94b93a2dc9fbdde5ffeba6bed Reviewed-on: https://code.wireshark.org/review/25661 Petri-Dish: Anders Broman <a.broman58@gmail.com> Petri-Dish: Dario Lombardo <lomato@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-02-07Include as "ui/summary.h", as is done elsewhere.Guy Harris1-1/+1
Change-Id: I832c74554854bf380984cab83a53e7ffe165ad84 Reviewed-on: https://code.wireshark.org/review/25658 Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-02-07Move summary.[ch] to libui.Guy Harris1-0/+230
Change-Id: I49f1eeb4fc3a90e436da116577a7d0c5ba982eee Reviewed-on: https://code.wireshark.org/review/25657 Reviewed-by: Guy Harris <guy@alum.mit.edu>