We always build the .c files in ui/win32 with Visual C++, so rename
them to .cpp and update CMakeLists.txt to match. Leave the C code mostly
intact for now, but this lets us take advantage of C++ features in the
future if desired.
It is a common use case to look at the signal raw values in hex.
This patch adds this for uint based values. Since the length of
the signal is not necessary 8, 16, 32, or 64 bit, this is done via
append_text.
The Octet string is an outlier amongst DNP3 objects as the variation
doesn't define a specific type of string but the length.
Presiously the length was not displayed in the packet details,
this change adds the length to the object header.
A sub-tlv has a 2-bytes type and a 2-bytes length, that includes
the stlv header. For this reason the full length of a stlv must be
over 4. This must be checked before converting the payload to a
string by subtracting 4 to the length.
Fix: #17459.
It has been added since its length is signed, while the underlying
bytes_to_str uses a size_t, causing an unwanted cast. Basically
passing a len < 0 is pointless.
Note that OPT_CUSTOM_STR_COPY is, specifically, a UTF-8 string.
Fix the comment for OPT_CUSTOM_STR_NO_COPY to say it's a UTF-8 string,
not binary data.
Add the mode adaptation protocol to the tree even when it is L.1
(no actual bytes), just with no subtree in that case. This is necessary
in order to access the preferences.
Commit 5b248ac4d0 updated LDAP but
didn't update the comment about the included file line number reference.
Commit the result of running asn2wrs.py to keep things consistent.
GSML parsing has a bug related to multiple submodules,
such that, the first submodule found in the GSDML needs
to be the PROFIsafe element, otherwise the description
is not parsed.
A frame can have multiple MPEG2 TS packets, and individual TSPs can have
the end of one fragmented higher level packet and the beginning of another.
The higher level packets can have protocols like MPE that set the
address and ports on packet_info for a given frame.
Thus, in order to properly reassemble fragments togther, don't use the
addresses and ports, but do use the stream (conversation + direction) that
assigns the fragment IDs.
We have to use dedicated runners for Windows builds, so create a
separate "if-merged" rule for them which includes only the
wireshark/wireshark repository.
Functions clock_gettime() and timespec_get() cover all the platforms
we support with sub-second resolution in a a portable manner. Fallback
to using time().
Pass a struct timespec to the log writer callback for maximum
flexibility.
Consistently use pcapng_compute_XXX_option_size() for routines to
compute the size of an option of type XXX and pcapng_write_XXX_option()
for routins to write out an option of type XXX.
Sort the routines by the order in which their option type values are
defined.
Have common routines that iterate over all the options, processing
comment and custom options in common code (as they're defined
independently of particular block types), with callbacks to handle the
options for particular block types.