wireshark/tools/pre-commit-ignore.conf
Guy Harris a34cc98b2a Put the main() and wmain() routines for CLI programs into a separate file.
That means that code is only in one place, rather than having copies of
it in each of those programs.

CLI programs that, on Windows, should get UTF-8 arguments rather than
arguments in the local code page should:

	include the top-level cli_main.h header;

	define the main function as real_main();

	be built with the top-level cli_main.c file.

On UN*X, cli_main.c has a main() program, and just passes the arguments
on to real_main().

On Windows, cli_main.c has a wmain() function that converts the UTF-16
arguments it's handed to UTF-8 arguments, using WideCharToMultiByte() so
that it doesn't use any functions other than those provided by the
system, and then calls real_main() with the argument count and UTF-8
arguments.

Change-Id: I8b11f01dbc5c63fce599d1bef9ad96cd92c3c01e
Reviewed-on: https://code.wireshark.org/review/31017
Petri-Dish: Guy Harris <guy@alum.mit.edu>
Tested-by: Petri Dish Buildbot
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-12-13 00:52:11 +00:00

27 lines
715 B
Text

# Files listed here are ignored by the git pre-commit hook for the purpose
# of checking for forbidden APIs and other dissector-specific glitches.
#
# Each line is compared against the output of 'git diff-index --name-only'.
# For example to skip checking this file add:
#
# tools/pre-commit-ignore.conf
#
# The pathname wildcards allowed are: '*', '?', character set '[abc]' or
# negated with '[!abc]'.
doc/packet-PROTOABBREV.c
epan/dissectors/asn1/*/packet-*-template.c
epan/dissectors/asn1/*/*asn
epan/nghttp2/*
epan/wmem/wmem_strbuf.c
epan/wmem/wmem_strutil.c
epan/wslua/init_wslua.c
extcap/*
image/stock_icons/*
cli_main.c
mmdbresolve.c
tools/lemon/*
wsutil/file_util.h
wsutil/strptime.c
wsutil/getopt_long.c