Age | Commit message (Collapse) | Author | Files | Lines |
|
Some strings contain semicolons, which meant g36db2df was terminating
our REs too early. Try terminating them with '}' followed by ';'.
Change-Id: I97f63351ef35c91e3123d9abd47576d47fea4b2b
Reviewed-on: https://code.wireshark.org/review/638
Reviewed-by: Gerald Combs <gerald@wireshark.org>
|
|
Update checkAPIs.pl to look for newlines in value_strings and
enum_val_t's. We now have to perform the check before we strip quoted
strings. Hopefully that won't cause a problem. Rename the check since
we do more than check for NULL termination.
Add modelines.
Fixes bug 9878.
Change-Id: I39dd910db60c7028ea4bdb58e8cfdb239c094748
Reviewed-on: https://code.wireshark.org/review/628
Reviewed-by: Gerald Combs <gerald@wireshark.org>
|
|
Do with tvb_get_stringz() what was done with tvb_get_string().
Redo the comments for the string get routines to try to give more detail
in a fashion that's a bit less hard to read.
Warn, in comments, of the problems with using
tvb_get_string()/tvb_get_stringz() (i.e., if your strings are non-ASCII,
all bytes with the 8th bit set are going be replaced by the Unicode
REPLACEMENT CHARACTER, and displayed as such).
Warn, in a comment, of the problems with tvb_get_const_stringz() (i.e.,
it gives you raw bytes, rather than guaranteed-to-be-valid UTF-8).
Update documentation and release notes appropriately.
Change-Id: Ibd3efb92a203861f507ce71bc8d04d19d9d38a93
Reviewed-on: https://code.wireshark.org/review/327
Reviewed-by: Guy Harris <guy@alum.mit.edu>
|
|
- rename tvb_length and similar to tvb_captured_length and similar; leave
#defines in place for backwards-compat, but mark them clearly as deprecated in
code comments and in checkAPI
- remove tvb_get_string as C code and just leave a #define in place for
backwards-compat; mark it clearly as deprecated in code comment and checkAPI
- update READMEs and sample dissector for all of the above
- while in the neighbourhood, make checkAPI skip (and warn) for missing files
instead of bailing on the whole check, so subsequent files still get checked
Change-Id: I32fc437896ca86ca73e9b49d5f50400adf8ec5ad
Reviewed-on: https://code.wireshark.org/review/311
Reviewed-by: Evan Huus <eapache@gmail.com>
|
|
$Id$ is pretty useless in git so don't enforce it in our source code.
Change-Id: Ie8b1b9627aabbca72c9c1dd93a9a76901e6967eb
Reviewed-on: https://code.wireshark.org/review/203
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Guy Harris <guy@alum.mit.edu>
|
|
sure they get counted in the proto_tree_add_text percentage.
Makes a few dissectors look a little better.
svn path=/trunk/; revision=54236
|
|
except it takes a wmem scope instead. Add the two emem equivalents to checkAPI
as (weakly) deprecated.
svn path=/trunk/; revision=53528
|
|
Disabled by default, but used when I want to go on an add filterability spree. convert_proto_tree_add_text.pl makes these easier to fix, so why not be pickier about the percentages that dissectors use.
svn path=/trunk/; revision=52392
|
|
a file. Warn about the "wrong" filetype and continue
svn path=/trunk/; revision=52105
|
|
(like a #define) at the beginning of a line before a value_string no longer
matches so a #define that includes the beginning of a value_string doesn't
confuse the script.
svn path=/trunk/; revision=52089
|
|
List options one by one
svn path=/trunk/; revision=52068
|
|
svn path=/trunk/; revision=52061
|
|
svn path=/trunk/; revision=52016
|
|
svn path=/trunk/; revision=52015
|
|
Add --check-addtext/--nocheck-addtext, --check-hf/--nocheck-hf and --debug to the usage output and format the usage output a little better.
svn path=/trunk/; revision=52006
|
|
svn path=/trunk/; revision=51782
|
|
proto_tree_add_text()s. I believe the intent was to ignore "small" dissectors that didn't have enough fields to qualify, but the previous logic ignored dissectors that were (almost) all proto_tree_add_text and no proto_tree_add_xxx.
I'm flexible on the definition of "small" (20 "fields"), but I think checkAPIs should flag the "all proto_tree_add_text" dissectors.
svn path=/trunk/; revision=50385
|
|
svn path=/trunk/; revision=48340
|
|
- Remove comments from the input string before checking hf[] entries;
- Remove code under '#if 0' before doing API checks.
svn path=/trunk/; revision=47447
|
|
proto_tree_add_item().
svn path=/trunk/; revision=46598
|
|
uncomment the code) check for being called with tvb_get_ptr().
svn path=/trunk/; revision=46326
|
|
Also check that they are all const.
svn path=/trunk/; revision=46294
|
|
for deprecated dissector add/remmove/... functions.
svn path=/trunk/; revision=45000
|
|
Also: improve error message slightly in the case of a missing NULL termination.
svn path=/trunk/; revision=44826
|
|
Also, remove some tabs.
svn path=/trunk/; revision=44824
|
|
svn path=/trunk/; revision=43939
|
|
return it, and use the return value.
svn path=/trunk/; revision=43818
|
|
calls an error.
Fix one case where we weren't counting an error (unregistered ett
variables).
svn path=/trunk/; revision=43817
|
|
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7429#c4 :
Add checks for calls to proto_tree_add_XXX (where XXX != item and a few other
functions) with an encoding (ENC_*) argument.
Also add a comment to checkAddTextCalls() about why 3 loops are used.
svn path=/trunk/; revision=43563
|
|
svn path=/trunk/; revision=43538
|
|
Replace tabs with spaces (for consistency).
svn path=/trunk/; revision=43213
|
|
svn path=/trunk/; revision=43040
|
|
that has the string "strlen" somewhere after a call to snprintf()).
svn path=/trunk/; revision=42950
|
|
there's a good chance we're doing something wrong.
svn path=/trunk/; revision=42947
|
|
Also: identify problematic fields by hf_variable_name instead of name or
abbreviation (the variable name is sure to be unique).
svn path=/trunk/; revision=42826
|
|
from makefiles (and thus from the buildbot).
The intention is to be able to tell when a human is running the tool so we
can provide more code-review guidance.
As a starter, enable the "too many proto_tree_add_text() calls" check when
a human is running the tool.
svn path=/trunk/; revision=41943
|
|
and with BASE_... in the 'display' field.
svn path=/trunk/; revision=41399
|
|
(Commented out until all the incorrect usages in Wireshark have been fixed).
svn path=/trunk/; revision=41380
|
|
Prohibit using FT_BOOLEANS with value_strings.
svn path=/trunk/; revision=41364
|
|
svn path=/trunk/; revision=41181
|
|
proto_tree_add_text() calls and compare that to the number of
proto_tree_add_<something else>() calls and complain if more than 50%
of the calls are add_text()'s.
proto_tree_add_text() calls whose returned proto_item is used are not counted
as hanging a subtree off a text item is an appropriate use for text items.
I chose 50% because even at that level there are many dissectors with "too many"
proto_tree_add_text()'s.
The function to do all of this is commented out for now for the same reason
plus the fact that it's pretty slow.
svn path=/trunk/; revision=40930
|
|
Add comment about Wireshark build defines G_DISABLE_DEPRECATED.
svn path=/trunk/; revision=40584
|
|
svn path=/trunk/; revision=40572
|
|
- Mark GDK functions which aren't used as 'E'
- Add GTK functions deprecated after GTK 2.20
- Add some comments about use of GTK_DISABLE_DEPRECATED
- reformat
...
svn path=/trunk/; revision=40569
|
|
such usage.
svn path=/trunk/; revision=40548
|
|
so do so. Add ZeroMemory to checkAPIs.pl.
svn path=/trunk/; revision=38584
|
|
svn path=/trunk/; revision=38357
|
|
svn path=/trunk/; revision=38202
|
|
GTK_WIDGET_NO_WINDOW() in pre-2.18 versions of GTK+. Treat calls to
GTK_WIDGET_NO_WINDOW() as an error in checkAPIs.pl.
svn path=/trunk/; revision=38197
|
|
svn path=/trunk/; revision=38196
|