[clang-tidy] Replace NULL with nullptr

Found with modernize-use-nullptr

Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
Rosen Penev
2019-11-18 18:34:50 -08:00
committed by ridiculousfish
parent 8d54e928cd
commit 1055ff321c
80 changed files with 721 additions and 710 deletions

View File

@@ -23,18 +23,18 @@ struct command_cmd_opts_t {
bool all_paths = false;
};
static const wchar_t *const short_options = L":ahqsv";
static const struct woption long_options[] = {{L"help", no_argument, NULL, 'h'},
{L"all", no_argument, NULL, 'a'},
{L"quiet", no_argument, NULL, 'q'},
{L"search", no_argument, NULL, 's'},
{NULL, 0, NULL, 0}};
static const struct woption long_options[] = {{L"help", no_argument, nullptr, 'h'},
{L"all", no_argument, nullptr, 'a'},
{L"quiet", no_argument, nullptr, 'q'},
{L"search", no_argument, nullptr, 's'},
{nullptr, 0, nullptr, 0}};
static int parse_cmd_opts(command_cmd_opts_t &opts, int *optind, int argc, wchar_t **argv,
parser_t &parser, io_streams_t &streams) {
wchar_t *cmd = argv[0];
int opt;
wgetopter_t w;
while ((opt = w.wgetopt_long(argc, argv, short_options, long_options, NULL)) != -1) {
while ((opt = w.wgetopt_long(argc, argv, short_options, long_options, nullptr)) != -1) {
switch (opt) {
case 'a': {
opts.all_paths = true;