mirror of
https://github.com/tmux/tmux.git
synced 2025-09-02 13:37:12 +00:00
yyerror should be void.
This commit is contained in:
@ -32,7 +32,7 @@
|
|||||||
|
|
||||||
static int yylex(void);
|
static int yylex(void);
|
||||||
static int yyparse(void);
|
static int yyparse(void);
|
||||||
static int printflike(1,2) yyerror(const char *, ...);
|
static void printflike(1,2) yyerror(const char *, ...);
|
||||||
|
|
||||||
static char *yylex_token(int);
|
static char *yylex_token(int);
|
||||||
static char *yylex_format(void);
|
static char *yylex_format(void);
|
||||||
@ -1127,7 +1127,7 @@ cmd_parse_from_arguments(struct args_value *values, u_int count,
|
|||||||
return (&pr);
|
return (&pr);
|
||||||
}
|
}
|
||||||
|
|
||||||
static int printflike(1, 2)
|
static void printflike(1, 2)
|
||||||
yyerror(const char *fmt, ...)
|
yyerror(const char *fmt, ...)
|
||||||
{
|
{
|
||||||
struct cmd_parse_state *ps = &parse_state;
|
struct cmd_parse_state *ps = &parse_state;
|
||||||
@ -1136,7 +1136,7 @@ yyerror(const char *fmt, ...)
|
|||||||
char *error;
|
char *error;
|
||||||
|
|
||||||
if (ps->error != NULL)
|
if (ps->error != NULL)
|
||||||
return (0);
|
return;
|
||||||
|
|
||||||
va_start(ap, fmt);
|
va_start(ap, fmt);
|
||||||
xvasprintf(&error, fmt, ap);
|
xvasprintf(&error, fmt, ap);
|
||||||
@ -1144,7 +1144,6 @@ yyerror(const char *fmt, ...)
|
|||||||
|
|
||||||
ps->error = cmd_parse_get_error(pi->file, pi->line, error);
|
ps->error = cmd_parse_get_error(pi->file, pi->line, error);
|
||||||
free(error);
|
free(error);
|
||||||
return (0);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
|
Reference in New Issue
Block a user