lemon: Make it build with __clang_analyzer__ defined
The static function handleswitch() is not compiled with __clang_analyzer__ defined, but it's used in OptInit() without any checks. Change to have an empty implementation for __clang_analyzer__. Change-Id: I73da2042ec64fdfa6910c02c059d36db491dc538 Reviewed-on: https://code.wireshark.org/review/28059 Petri-Dish: Stig Bjørlykke <stig@bjorlykke.org> Tested-by: Petri Dish Buildbot Reviewed-by: Dario Lombardo <lomato@gmail.com> Reviewed-by: Anders Broman <a.broman58@gmail.com>
This commit is contained in:
parent
79da59e31f
commit
6bb5a7af66
|
@ -2058,18 +2058,18 @@ static int handleflags(int i, FILE *err)
|
||||||
return errcnt;
|
return errcnt;
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef __clang_analyzer__
|
|
||||||
/*
|
/*
|
||||||
** Process a command line switch which has an argument.
|
** Process a command line switch which has an argument.
|
||||||
*/
|
*/
|
||||||
static int handleswitch(int i, FILE *err)
|
static int handleswitch(int i, FILE *err)
|
||||||
{
|
{
|
||||||
|
int errcnt = 0;
|
||||||
|
#ifndef __clang_analyzer__
|
||||||
int lv = 0;
|
int lv = 0;
|
||||||
double dv = 0.0;
|
double dv = 0.0;
|
||||||
char *sv = 0, *end;
|
char *sv = 0, *end;
|
||||||
char *cp;
|
char *cp;
|
||||||
int j;
|
int j;
|
||||||
int errcnt = 0;
|
|
||||||
cp = strchr(argv[i],'=');
|
cp = strchr(argv[i],'=');
|
||||||
assert( cp!=0 );
|
assert( cp!=0 );
|
||||||
*cp = 0;
|
*cp = 0;
|
||||||
|
@ -2146,9 +2146,9 @@ static int handleswitch(int i, FILE *err)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
return errcnt;
|
return errcnt;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
|
|
||||||
int OptInit(char **a, struct s_options *o, FILE *err)
|
int OptInit(char **a, struct s_options *o, FILE *err)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue