mirror of
https://github.com/sudo-project/sudo.git
synced 2025-08-22 09:57:41 +00:00
Don't include <sys/param.h>. We only needed it for MAXPATHLEN,
MAXHOSTNAMELEN and the MIN/MAX macros. We now use PATH_MAX and HOST_NAME_MAX throughout without falling back on MAXPATHLEN or MAXHOSTNAMELEN and define our own MIN/MAX macros as needed.
This commit is contained in:
parent
3c9da162e4
commit
1d7072fe09
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/time.h>
|
||||
#ifdef HAVE_FLOCK
|
||||
# include <sys/file.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -19,7 +19,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -18,7 +18,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef HAVE_STRING_H
|
||||
# include <string.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/uio.h>
|
||||
#include <stdio.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -18,7 +18,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <unistd.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -29,7 +29,7 @@
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <errno.h>
|
||||
|
@ -52,7 +52,7 @@
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <stdio.h>
|
||||
|
@ -42,7 +42,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -82,26 +82,18 @@
|
||||
#endif
|
||||
|
||||
#ifndef PATH_MAX
|
||||
# ifdef MAXPATHLEN
|
||||
# define PATH_MAX MAXPATHLEN
|
||||
# ifdef _POSIX_PATH_MAX
|
||||
# define PATH_MAX _POSIX_PATH_MAX
|
||||
# else
|
||||
# ifdef _POSIX_PATH_MAX
|
||||
# define PATH_MAX _POSIX_PATH_MAX
|
||||
# else
|
||||
# define PATH_MAX 1024
|
||||
# endif
|
||||
# define PATH_MAX 256
|
||||
# endif
|
||||
#endif
|
||||
|
||||
#ifndef HOST_NAME_MAX
|
||||
# ifdef MAXHOSTNAMELEN
|
||||
# define HOST_NAME_MAX MAXHOSTNAMELEN
|
||||
# ifdef _POSIX_HOST_NAME_MAX
|
||||
# define HOST_NAME_MAX _POSIX_HOST_NAME_MAX
|
||||
# else
|
||||
# ifdef _POSIX_HOST_NAME_MAX
|
||||
# define HOST_NAME_MAX _POSIX_HOST_NAME_MAX
|
||||
# else
|
||||
# define HOST_NAME_MAX 64
|
||||
# endif
|
||||
# define HOST_NAME_MAX 255
|
||||
# endif
|
||||
#endif
|
||||
|
||||
@ -148,7 +140,7 @@
|
||||
#endif
|
||||
|
||||
/*
|
||||
* BSD defines these in <sys/param.h> but others may not.
|
||||
* BSD defines these in <sys/param.h> but we don't include that anymore.
|
||||
*/
|
||||
#ifndef MIN
|
||||
# define MIN(a,b) (((a)<(b))?(a):(b))
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/wait.h>
|
||||
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -15,7 +15,6 @@
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <stdio.h>
|
||||
|
@ -20,7 +20,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -21,7 +21,6 @@
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -36,7 +36,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -25,7 +25,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -26,7 +26,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -24,7 +24,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -16,7 +16,6 @@
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -23,7 +23,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -23,7 +23,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef HAVE_STRING_H
|
||||
# include <string.h>
|
||||
|
@ -63,7 +63,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
@ -161,7 +160,7 @@ sudoerserror(const char *s)
|
||||
parse_error = true;
|
||||
debug_return;
|
||||
}
|
||||
#line 128 "gram.y"
|
||||
#line 127 "gram.y"
|
||||
#ifndef YYSTYPE_DEFINED
|
||||
#define YYSTYPE_DEFINED
|
||||
typedef union {
|
||||
@ -178,7 +177,7 @@ typedef union {
|
||||
int tok;
|
||||
} YYSTYPE;
|
||||
#endif /* YYSTYPE_DEFINED */
|
||||
#line 181 "gram.c"
|
||||
#line 180 "gram.c"
|
||||
#define COMMAND 257
|
||||
#define ALIAS 258
|
||||
#define DEFVAR 259
|
||||
@ -705,7 +704,7 @@ short *yyss;
|
||||
short *yysslim;
|
||||
YYSTYPE *yyvs;
|
||||
int yystacksize;
|
||||
#line 680 "gram.y"
|
||||
#line 679 "gram.y"
|
||||
static struct defaults *
|
||||
new_default(char *var, char *val, int op)
|
||||
{
|
||||
@ -908,7 +907,7 @@ init_parser(const char *path, bool quiet)
|
||||
|
||||
debug_return;
|
||||
}
|
||||
#line 859 "gram.c"
|
||||
#line 858 "gram.c"
|
||||
/* allocate initial stack or double stack size, up to YYMAXDEPTH */
|
||||
#if defined(__cplusplus) || defined(__STDC__)
|
||||
static int yygrowstack(void)
|
||||
@ -1111,127 +1110,127 @@ yyreduce:
|
||||
switch (yyn)
|
||||
{
|
||||
case 1:
|
||||
#line 210 "gram.y"
|
||||
#line 209 "gram.y"
|
||||
{ ; }
|
||||
break;
|
||||
case 5:
|
||||
#line 218 "gram.y"
|
||||
#line 217 "gram.y"
|
||||
{
|
||||
;
|
||||
}
|
||||
break;
|
||||
case 6:
|
||||
#line 221 "gram.y"
|
||||
#line 220 "gram.y"
|
||||
{
|
||||
yyerrok;
|
||||
}
|
||||
break;
|
||||
case 7:
|
||||
#line 224 "gram.y"
|
||||
#line 223 "gram.y"
|
||||
{
|
||||
add_userspec(yyvsp[-1].member, yyvsp[0].privilege);
|
||||
}
|
||||
break;
|
||||
case 8:
|
||||
#line 227 "gram.y"
|
||||
#line 226 "gram.y"
|
||||
{
|
||||
;
|
||||
}
|
||||
break;
|
||||
case 9:
|
||||
#line 230 "gram.y"
|
||||
#line 229 "gram.y"
|
||||
{
|
||||
;
|
||||
}
|
||||
break;
|
||||
case 10:
|
||||
#line 233 "gram.y"
|
||||
#line 232 "gram.y"
|
||||
{
|
||||
;
|
||||
}
|
||||
break;
|
||||
case 11:
|
||||
#line 236 "gram.y"
|
||||
#line 235 "gram.y"
|
||||
{
|
||||
;
|
||||
}
|
||||
break;
|
||||
case 12:
|
||||
#line 239 "gram.y"
|
||||
#line 238 "gram.y"
|
||||
{
|
||||
add_defaults(DEFAULTS, NULL, yyvsp[0].defaults);
|
||||
}
|
||||
break;
|
||||
case 13:
|
||||
#line 242 "gram.y"
|
||||
#line 241 "gram.y"
|
||||
{
|
||||
add_defaults(DEFAULTS_USER, yyvsp[-1].member, yyvsp[0].defaults);
|
||||
}
|
||||
break;
|
||||
case 14:
|
||||
#line 245 "gram.y"
|
||||
#line 244 "gram.y"
|
||||
{
|
||||
add_defaults(DEFAULTS_RUNAS, yyvsp[-1].member, yyvsp[0].defaults);
|
||||
}
|
||||
break;
|
||||
case 15:
|
||||
#line 248 "gram.y"
|
||||
#line 247 "gram.y"
|
||||
{
|
||||
add_defaults(DEFAULTS_HOST, yyvsp[-1].member, yyvsp[0].defaults);
|
||||
}
|
||||
break;
|
||||
case 16:
|
||||
#line 251 "gram.y"
|
||||
#line 250 "gram.y"
|
||||
{
|
||||
add_defaults(DEFAULTS_CMND, yyvsp[-1].member, yyvsp[0].defaults);
|
||||
}
|
||||
break;
|
||||
case 18:
|
||||
#line 257 "gram.y"
|
||||
#line 256 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].defaults, yyvsp[0].defaults);
|
||||
yyval.defaults = yyvsp[-2].defaults;
|
||||
}
|
||||
break;
|
||||
case 19:
|
||||
#line 263 "gram.y"
|
||||
#line 262 "gram.y"
|
||||
{
|
||||
yyval.defaults = new_default(yyvsp[0].string, NULL, true);
|
||||
}
|
||||
break;
|
||||
case 20:
|
||||
#line 266 "gram.y"
|
||||
#line 265 "gram.y"
|
||||
{
|
||||
yyval.defaults = new_default(yyvsp[0].string, NULL, false);
|
||||
}
|
||||
break;
|
||||
case 21:
|
||||
#line 269 "gram.y"
|
||||
#line 268 "gram.y"
|
||||
{
|
||||
yyval.defaults = new_default(yyvsp[-2].string, yyvsp[0].string, true);
|
||||
}
|
||||
break;
|
||||
case 22:
|
||||
#line 272 "gram.y"
|
||||
#line 271 "gram.y"
|
||||
{
|
||||
yyval.defaults = new_default(yyvsp[-2].string, yyvsp[0].string, '+');
|
||||
}
|
||||
break;
|
||||
case 23:
|
||||
#line 275 "gram.y"
|
||||
#line 274 "gram.y"
|
||||
{
|
||||
yyval.defaults = new_default(yyvsp[-2].string, yyvsp[0].string, '-');
|
||||
}
|
||||
break;
|
||||
case 25:
|
||||
#line 281 "gram.y"
|
||||
#line 280 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].privilege, yyvsp[0].privilege);
|
||||
yyval.privilege = yyvsp[-2].privilege;
|
||||
}
|
||||
break;
|
||||
case 26:
|
||||
#line 287 "gram.y"
|
||||
#line 286 "gram.y"
|
||||
{
|
||||
struct privilege *p = ecalloc(1, sizeof(*p));
|
||||
list2tq(&p->hostlist, yyvsp[-2].member);
|
||||
@ -1242,51 +1241,51 @@ case 26:
|
||||
}
|
||||
break;
|
||||
case 27:
|
||||
#line 297 "gram.y"
|
||||
#line 296 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = false;
|
||||
}
|
||||
break;
|
||||
case 28:
|
||||
#line 301 "gram.y"
|
||||
#line 300 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = true;
|
||||
}
|
||||
break;
|
||||
case 29:
|
||||
#line 307 "gram.y"
|
||||
#line 306 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, ALIAS);
|
||||
}
|
||||
break;
|
||||
case 30:
|
||||
#line 310 "gram.y"
|
||||
#line 309 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(NULL, ALL);
|
||||
}
|
||||
break;
|
||||
case 31:
|
||||
#line 313 "gram.y"
|
||||
#line 312 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, NETGROUP);
|
||||
}
|
||||
break;
|
||||
case 32:
|
||||
#line 316 "gram.y"
|
||||
#line 315 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, NTWKADDR);
|
||||
}
|
||||
break;
|
||||
case 33:
|
||||
#line 319 "gram.y"
|
||||
#line 318 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, WORD);
|
||||
}
|
||||
break;
|
||||
case 35:
|
||||
#line 325 "gram.y"
|
||||
#line 324 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].cmndspec, yyvsp[0].cmndspec);
|
||||
#ifdef HAVE_SELINUX
|
||||
@ -1326,7 +1325,7 @@ case 35:
|
||||
}
|
||||
break;
|
||||
case 36:
|
||||
#line 364 "gram.y"
|
||||
#line 363 "gram.y"
|
||||
{
|
||||
struct cmndspec *cs = ecalloc(1, sizeof(*cs));
|
||||
if (yyvsp[-4].runas != NULL) {
|
||||
@ -1357,127 +1356,127 @@ case 36:
|
||||
}
|
||||
break;
|
||||
case 37:
|
||||
#line 394 "gram.y"
|
||||
#line 393 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = false;
|
||||
}
|
||||
break;
|
||||
case 38:
|
||||
#line 398 "gram.y"
|
||||
#line 397 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = true;
|
||||
}
|
||||
break;
|
||||
case 39:
|
||||
#line 404 "gram.y"
|
||||
#line 403 "gram.y"
|
||||
{
|
||||
yyval.string = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 40:
|
||||
#line 409 "gram.y"
|
||||
#line 408 "gram.y"
|
||||
{
|
||||
yyval.string = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 41:
|
||||
#line 414 "gram.y"
|
||||
#line 413 "gram.y"
|
||||
{
|
||||
yyval.seinfo.role = NULL;
|
||||
yyval.seinfo.type = NULL;
|
||||
}
|
||||
break;
|
||||
case 42:
|
||||
#line 418 "gram.y"
|
||||
#line 417 "gram.y"
|
||||
{
|
||||
yyval.seinfo.role = yyvsp[0].string;
|
||||
yyval.seinfo.type = NULL;
|
||||
}
|
||||
break;
|
||||
case 43:
|
||||
#line 422 "gram.y"
|
||||
#line 421 "gram.y"
|
||||
{
|
||||
yyval.seinfo.type = yyvsp[0].string;
|
||||
yyval.seinfo.role = NULL;
|
||||
}
|
||||
break;
|
||||
case 44:
|
||||
#line 426 "gram.y"
|
||||
#line 425 "gram.y"
|
||||
{
|
||||
yyval.seinfo.role = yyvsp[-1].string;
|
||||
yyval.seinfo.type = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 45:
|
||||
#line 430 "gram.y"
|
||||
#line 429 "gram.y"
|
||||
{
|
||||
yyval.seinfo.type = yyvsp[-1].string;
|
||||
yyval.seinfo.role = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 46:
|
||||
#line 436 "gram.y"
|
||||
#line 435 "gram.y"
|
||||
{
|
||||
yyval.string = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 47:
|
||||
#line 440 "gram.y"
|
||||
#line 439 "gram.y"
|
||||
{
|
||||
yyval.string = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 48:
|
||||
#line 445 "gram.y"
|
||||
#line 444 "gram.y"
|
||||
{
|
||||
yyval.privinfo.privs = NULL;
|
||||
yyval.privinfo.limitprivs = NULL;
|
||||
}
|
||||
break;
|
||||
case 49:
|
||||
#line 449 "gram.y"
|
||||
#line 448 "gram.y"
|
||||
{
|
||||
yyval.privinfo.privs = yyvsp[0].string;
|
||||
yyval.privinfo.limitprivs = NULL;
|
||||
}
|
||||
break;
|
||||
case 50:
|
||||
#line 453 "gram.y"
|
||||
#line 452 "gram.y"
|
||||
{
|
||||
yyval.privinfo.privs = NULL;
|
||||
yyval.privinfo.limitprivs = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 51:
|
||||
#line 457 "gram.y"
|
||||
#line 456 "gram.y"
|
||||
{
|
||||
yyval.privinfo.privs = yyvsp[-1].string;
|
||||
yyval.privinfo.limitprivs = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 52:
|
||||
#line 461 "gram.y"
|
||||
#line 460 "gram.y"
|
||||
{
|
||||
yyval.privinfo.limitprivs = yyvsp[-1].string;
|
||||
yyval.privinfo.privs = yyvsp[0].string;
|
||||
}
|
||||
break;
|
||||
case 53:
|
||||
#line 466 "gram.y"
|
||||
#line 465 "gram.y"
|
||||
{
|
||||
yyval.runas = NULL;
|
||||
}
|
||||
break;
|
||||
case 54:
|
||||
#line 469 "gram.y"
|
||||
#line 468 "gram.y"
|
||||
{
|
||||
yyval.runas = yyvsp[-1].runas;
|
||||
}
|
||||
break;
|
||||
case 55:
|
||||
#line 474 "gram.y"
|
||||
#line 473 "gram.y"
|
||||
{
|
||||
yyval.runas = ecalloc(1, sizeof(struct runascontainer));
|
||||
yyval.runas->runasusers = new_member(NULL, MYSELF);
|
||||
@ -1485,7 +1484,7 @@ case 55:
|
||||
}
|
||||
break;
|
||||
case 56:
|
||||
#line 479 "gram.y"
|
||||
#line 478 "gram.y"
|
||||
{
|
||||
yyval.runas = ecalloc(1, sizeof(struct runascontainer));
|
||||
yyval.runas->runasusers = yyvsp[0].member;
|
||||
@ -1493,7 +1492,7 @@ case 56:
|
||||
}
|
||||
break;
|
||||
case 57:
|
||||
#line 484 "gram.y"
|
||||
#line 483 "gram.y"
|
||||
{
|
||||
yyval.runas = ecalloc(1, sizeof(struct runascontainer));
|
||||
yyval.runas->runasusers = yyvsp[-2].member;
|
||||
@ -1501,7 +1500,7 @@ case 57:
|
||||
}
|
||||
break;
|
||||
case 58:
|
||||
#line 489 "gram.y"
|
||||
#line 488 "gram.y"
|
||||
{
|
||||
yyval.runas = ecalloc(1, sizeof(struct runascontainer));
|
||||
/* $$->runasusers = NULL; */
|
||||
@ -1509,7 +1508,7 @@ case 58:
|
||||
}
|
||||
break;
|
||||
case 59:
|
||||
#line 494 "gram.y"
|
||||
#line 493 "gram.y"
|
||||
{
|
||||
yyval.runas = ecalloc(1, sizeof(struct runascontainer));
|
||||
yyval.runas->runasusers = new_member(NULL, MYSELF);
|
||||
@ -1517,86 +1516,86 @@ case 59:
|
||||
}
|
||||
break;
|
||||
case 60:
|
||||
#line 501 "gram.y"
|
||||
#line 500 "gram.y"
|
||||
{
|
||||
yyval.tag.nopasswd = yyval.tag.noexec = yyval.tag.setenv =
|
||||
yyval.tag.log_input = yyval.tag.log_output = UNSPEC;
|
||||
}
|
||||
break;
|
||||
case 61:
|
||||
#line 505 "gram.y"
|
||||
#line 504 "gram.y"
|
||||
{
|
||||
yyval.tag.nopasswd = true;
|
||||
}
|
||||
break;
|
||||
case 62:
|
||||
#line 508 "gram.y"
|
||||
#line 507 "gram.y"
|
||||
{
|
||||
yyval.tag.nopasswd = false;
|
||||
}
|
||||
break;
|
||||
case 63:
|
||||
#line 511 "gram.y"
|
||||
#line 510 "gram.y"
|
||||
{
|
||||
yyval.tag.noexec = true;
|
||||
}
|
||||
break;
|
||||
case 64:
|
||||
#line 514 "gram.y"
|
||||
#line 513 "gram.y"
|
||||
{
|
||||
yyval.tag.noexec = false;
|
||||
}
|
||||
break;
|
||||
case 65:
|
||||
#line 517 "gram.y"
|
||||
#line 516 "gram.y"
|
||||
{
|
||||
yyval.tag.setenv = true;
|
||||
}
|
||||
break;
|
||||
case 66:
|
||||
#line 520 "gram.y"
|
||||
#line 519 "gram.y"
|
||||
{
|
||||
yyval.tag.setenv = false;
|
||||
}
|
||||
break;
|
||||
case 67:
|
||||
#line 523 "gram.y"
|
||||
#line 522 "gram.y"
|
||||
{
|
||||
yyval.tag.log_input = true;
|
||||
}
|
||||
break;
|
||||
case 68:
|
||||
#line 526 "gram.y"
|
||||
#line 525 "gram.y"
|
||||
{
|
||||
yyval.tag.log_input = false;
|
||||
}
|
||||
break;
|
||||
case 69:
|
||||
#line 529 "gram.y"
|
||||
#line 528 "gram.y"
|
||||
{
|
||||
yyval.tag.log_output = true;
|
||||
}
|
||||
break;
|
||||
case 70:
|
||||
#line 532 "gram.y"
|
||||
#line 531 "gram.y"
|
||||
{
|
||||
yyval.tag.log_output = false;
|
||||
}
|
||||
break;
|
||||
case 71:
|
||||
#line 537 "gram.y"
|
||||
#line 536 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(NULL, ALL);
|
||||
}
|
||||
break;
|
||||
case 72:
|
||||
#line 540 "gram.y"
|
||||
#line 539 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, ALIAS);
|
||||
}
|
||||
break;
|
||||
case 73:
|
||||
#line 543 "gram.y"
|
||||
#line 542 "gram.y"
|
||||
{
|
||||
struct sudo_command *c = ecalloc(1, sizeof(*c));
|
||||
c->cmnd = yyvsp[0].command.cmnd;
|
||||
@ -1605,7 +1604,7 @@ case 73:
|
||||
}
|
||||
break;
|
||||
case 76:
|
||||
#line 555 "gram.y"
|
||||
#line 554 "gram.y"
|
||||
{
|
||||
char *s;
|
||||
if ((s = alias_add(yyvsp[-2].string, HOSTALIAS, yyvsp[0].member)) != NULL) {
|
||||
@ -1615,14 +1614,14 @@ case 76:
|
||||
}
|
||||
break;
|
||||
case 78:
|
||||
#line 565 "gram.y"
|
||||
#line 564 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].member, yyvsp[0].member);
|
||||
yyval.member = yyvsp[-2].member;
|
||||
}
|
||||
break;
|
||||
case 81:
|
||||
#line 575 "gram.y"
|
||||
#line 574 "gram.y"
|
||||
{
|
||||
char *s;
|
||||
if ((s = alias_add(yyvsp[-2].string, CMNDALIAS, yyvsp[0].member)) != NULL) {
|
||||
@ -1632,14 +1631,14 @@ case 81:
|
||||
}
|
||||
break;
|
||||
case 83:
|
||||
#line 585 "gram.y"
|
||||
#line 584 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].member, yyvsp[0].member);
|
||||
yyval.member = yyvsp[-2].member;
|
||||
}
|
||||
break;
|
||||
case 86:
|
||||
#line 595 "gram.y"
|
||||
#line 594 "gram.y"
|
||||
{
|
||||
char *s;
|
||||
if ((s = alias_add(yyvsp[-2].string, RUNASALIAS, yyvsp[0].member)) != NULL) {
|
||||
@ -1649,7 +1648,7 @@ case 86:
|
||||
}
|
||||
break;
|
||||
case 89:
|
||||
#line 608 "gram.y"
|
||||
#line 607 "gram.y"
|
||||
{
|
||||
char *s;
|
||||
if ((s = alias_add(yyvsp[-2].string, USERALIAS, yyvsp[0].member)) != NULL) {
|
||||
@ -1659,96 +1658,96 @@ case 89:
|
||||
}
|
||||
break;
|
||||
case 91:
|
||||
#line 618 "gram.y"
|
||||
#line 617 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].member, yyvsp[0].member);
|
||||
yyval.member = yyvsp[-2].member;
|
||||
}
|
||||
break;
|
||||
case 92:
|
||||
#line 624 "gram.y"
|
||||
#line 623 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = false;
|
||||
}
|
||||
break;
|
||||
case 93:
|
||||
#line 628 "gram.y"
|
||||
#line 627 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = true;
|
||||
}
|
||||
break;
|
||||
case 94:
|
||||
#line 634 "gram.y"
|
||||
#line 633 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, ALIAS);
|
||||
}
|
||||
break;
|
||||
case 95:
|
||||
#line 637 "gram.y"
|
||||
#line 636 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(NULL, ALL);
|
||||
}
|
||||
break;
|
||||
case 96:
|
||||
#line 640 "gram.y"
|
||||
#line 639 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, NETGROUP);
|
||||
}
|
||||
break;
|
||||
case 97:
|
||||
#line 643 "gram.y"
|
||||
#line 642 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, USERGROUP);
|
||||
}
|
||||
break;
|
||||
case 98:
|
||||
#line 646 "gram.y"
|
||||
#line 645 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, WORD);
|
||||
}
|
||||
break;
|
||||
case 100:
|
||||
#line 652 "gram.y"
|
||||
#line 651 "gram.y"
|
||||
{
|
||||
list_append(yyvsp[-2].member, yyvsp[0].member);
|
||||
yyval.member = yyvsp[-2].member;
|
||||
}
|
||||
break;
|
||||
case 101:
|
||||
#line 658 "gram.y"
|
||||
#line 657 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = false;
|
||||
}
|
||||
break;
|
||||
case 102:
|
||||
#line 662 "gram.y"
|
||||
#line 661 "gram.y"
|
||||
{
|
||||
yyval.member = yyvsp[0].member;
|
||||
yyval.member->negated = true;
|
||||
}
|
||||
break;
|
||||
case 103:
|
||||
#line 668 "gram.y"
|
||||
#line 667 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, ALIAS);
|
||||
}
|
||||
break;
|
||||
case 104:
|
||||
#line 671 "gram.y"
|
||||
#line 670 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(NULL, ALL);
|
||||
}
|
||||
break;
|
||||
case 105:
|
||||
#line 674 "gram.y"
|
||||
#line 673 "gram.y"
|
||||
{
|
||||
yyval.member = new_member(yyvsp[0].string, WORD);
|
||||
}
|
||||
break;
|
||||
#line 1699 "gram.c"
|
||||
#line 1698 "gram.c"
|
||||
}
|
||||
yyssp -= yym;
|
||||
yystate = *yyssp;
|
||||
|
@ -25,7 +25,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/time.h>
|
||||
#include <stdio.h>
|
||||
|
@ -18,7 +18,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/time.h>
|
||||
#include <stdio.h>
|
||||
|
@ -20,7 +20,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
@ -48,7 +47,6 @@
|
||||
#include <grp.h>
|
||||
#include <netinet/in.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
#ifdef HAVE_LBER_H
|
||||
# include <lber.h>
|
||||
#endif
|
||||
|
@ -25,7 +25,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/ioctl.h>
|
||||
#include <sys/wait.h>
|
||||
|
@ -24,7 +24,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
@ -56,7 +55,6 @@
|
||||
#include <ctype.h>
|
||||
#include <pwd.h>
|
||||
#include <grp.h>
|
||||
#include <netdb.h>
|
||||
#ifdef HAVE_DIRENT_H
|
||||
# include <dirent.h>
|
||||
# define NAMLEN(dirent) strlen((dirent)->d_name)
|
||||
|
@ -45,7 +45,6 @@
|
||||
#endif /* HAVE_UNISTD_H */
|
||||
#include <netinet/in.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
|
||||
#include "sudoers.h"
|
||||
#include "interfaces.h"
|
||||
|
@ -19,7 +19,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <netinet/in.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -43,7 +43,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -41,7 +41,6 @@
|
||||
|
||||
#include <netinet/in.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
|
||||
#define SUDO_ERROR_WRAP 0
|
||||
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -21,7 +21,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <stdio.h>
|
||||
|
@ -28,7 +28,6 @@
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/socket.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/uio.h>
|
||||
#ifdef HAVE_SYS_SYSMACROS_H
|
||||
# include <sys/sysmacros.h>
|
||||
|
@ -25,7 +25,6 @@
|
||||
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/socket.h>
|
||||
@ -59,7 +58,6 @@
|
||||
#include <errno.h>
|
||||
#include <netinet/in.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
|
||||
#include "tsgetgrpw.h"
|
||||
#include "sudoers.h"
|
||||
|
@ -22,7 +22,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/stat.h>
|
||||
#ifdef __linux__
|
||||
|
@ -1437,7 +1437,6 @@ char *yytext;
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
@ -1528,7 +1527,7 @@ int (*trace_print)(const char *msg) = sudoers_trace_print;
|
||||
|
||||
#define INSTR 5
|
||||
|
||||
#line 1531 "lex.sudoers.c"
|
||||
#line 1530 "lex.sudoers.c"
|
||||
|
||||
/* Macros after this point can all be overridden by user definitions in
|
||||
* section 1.
|
||||
@ -1682,9 +1681,9 @@ YY_DECL
|
||||
register char *yy_cp, *yy_bp;
|
||||
register int yy_act;
|
||||
|
||||
#line 133 "toke.l"
|
||||
#line 132 "toke.l"
|
||||
|
||||
#line 1687 "lex.sudoers.c"
|
||||
#line 1686 "lex.sudoers.c"
|
||||
|
||||
if ( yy_init )
|
||||
{
|
||||
@ -1770,7 +1769,7 @@ do_action: /* This label is used only to access EOF actions. */
|
||||
|
||||
case 1:
|
||||
YY_RULE_SETUP
|
||||
#line 134 "toke.l"
|
||||
#line 133 "toke.l"
|
||||
{
|
||||
LEXTRACE(", ");
|
||||
LEXRETURN(',');
|
||||
@ -1778,12 +1777,12 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 2:
|
||||
YY_RULE_SETUP
|
||||
#line 139 "toke.l"
|
||||
#line 138 "toke.l"
|
||||
BEGIN STARTDEFS;
|
||||
YY_BREAK
|
||||
case 3:
|
||||
YY_RULE_SETUP
|
||||
#line 141 "toke.l"
|
||||
#line 140 "toke.l"
|
||||
{
|
||||
BEGIN INDEFS;
|
||||
LEXTRACE("DEFVAR ");
|
||||
@ -1795,7 +1794,7 @@ YY_RULE_SETUP
|
||||
|
||||
case 4:
|
||||
YY_RULE_SETUP
|
||||
#line 150 "toke.l"
|
||||
#line 149 "toke.l"
|
||||
{
|
||||
BEGIN STARTDEFS;
|
||||
LEXTRACE(", ");
|
||||
@ -1804,7 +1803,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 5:
|
||||
YY_RULE_SETUP
|
||||
#line 156 "toke.l"
|
||||
#line 155 "toke.l"
|
||||
{
|
||||
LEXTRACE("= ");
|
||||
LEXRETURN('=');
|
||||
@ -1812,7 +1811,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 6:
|
||||
YY_RULE_SETUP
|
||||
#line 161 "toke.l"
|
||||
#line 160 "toke.l"
|
||||
{
|
||||
LEXTRACE("+= ");
|
||||
LEXRETURN('+');
|
||||
@ -1820,7 +1819,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 7:
|
||||
YY_RULE_SETUP
|
||||
#line 166 "toke.l"
|
||||
#line 165 "toke.l"
|
||||
{
|
||||
LEXTRACE("-= ");
|
||||
LEXRETURN('-');
|
||||
@ -1828,7 +1827,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 8:
|
||||
YY_RULE_SETUP
|
||||
#line 171 "toke.l"
|
||||
#line 170 "toke.l"
|
||||
{
|
||||
LEXTRACE("BEGINSTR ");
|
||||
sudoerslval.string = NULL;
|
||||
@ -1838,7 +1837,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 9:
|
||||
YY_RULE_SETUP
|
||||
#line 178 "toke.l"
|
||||
#line 177 "toke.l"
|
||||
{
|
||||
LEXTRACE("WORD(2) ");
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
@ -1850,7 +1849,7 @@ YY_RULE_SETUP
|
||||
|
||||
case 10:
|
||||
YY_RULE_SETUP
|
||||
#line 187 "toke.l"
|
||||
#line 186 "toke.l"
|
||||
{
|
||||
/* Line continuation char followed by newline. */
|
||||
sudolineno++;
|
||||
@ -1859,7 +1858,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 11:
|
||||
YY_RULE_SETUP
|
||||
#line 193 "toke.l"
|
||||
#line 192 "toke.l"
|
||||
{
|
||||
LEXTRACE("ENDSTR ");
|
||||
BEGIN prev_state;
|
||||
@ -1894,7 +1893,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 12:
|
||||
YY_RULE_SETUP
|
||||
#line 225 "toke.l"
|
||||
#line 224 "toke.l"
|
||||
{
|
||||
LEXTRACE("BACKSLASH ");
|
||||
if (!append(sudoerstext, sudoersleng))
|
||||
@ -1903,7 +1902,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 13:
|
||||
YY_RULE_SETUP
|
||||
#line 231 "toke.l"
|
||||
#line 230 "toke.l"
|
||||
{
|
||||
LEXTRACE("STRBODY ");
|
||||
if (!append(sudoerstext, sudoersleng))
|
||||
@ -1914,7 +1913,7 @@ YY_RULE_SETUP
|
||||
|
||||
case 14:
|
||||
YY_RULE_SETUP
|
||||
#line 239 "toke.l"
|
||||
#line 238 "toke.l"
|
||||
{
|
||||
/* quoted fnmatch glob char, pass verbatim */
|
||||
LEXTRACE("QUOTEDCHAR ");
|
||||
@ -1925,7 +1924,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 15:
|
||||
YY_RULE_SETUP
|
||||
#line 247 "toke.l"
|
||||
#line 246 "toke.l"
|
||||
{
|
||||
/* quoted sudoers special char, strip backslash */
|
||||
LEXTRACE("QUOTEDCHAR ");
|
||||
@ -1936,7 +1935,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 16:
|
||||
YY_RULE_SETUP
|
||||
#line 255 "toke.l"
|
||||
#line 254 "toke.l"
|
||||
{
|
||||
BEGIN INITIAL;
|
||||
yyless(0);
|
||||
@ -1945,7 +1944,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 17:
|
||||
YY_RULE_SETUP
|
||||
#line 261 "toke.l"
|
||||
#line 260 "toke.l"
|
||||
{
|
||||
LEXTRACE("ARG ");
|
||||
if (!fill_args(sudoerstext, sudoersleng, sawspace))
|
||||
@ -1956,7 +1955,7 @@ YY_RULE_SETUP
|
||||
|
||||
case 18:
|
||||
YY_RULE_SETUP
|
||||
#line 269 "toke.l"
|
||||
#line 268 "toke.l"
|
||||
{
|
||||
char *path;
|
||||
|
||||
@ -1977,7 +1976,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 19:
|
||||
YY_RULE_SETUP
|
||||
#line 287 "toke.l"
|
||||
#line 286 "toke.l"
|
||||
{
|
||||
char *path;
|
||||
|
||||
@ -2001,7 +2000,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 20:
|
||||
YY_RULE_SETUP
|
||||
#line 308 "toke.l"
|
||||
#line 307 "toke.l"
|
||||
{
|
||||
char deftype;
|
||||
int n;
|
||||
@ -2044,7 +2043,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 21:
|
||||
YY_RULE_SETUP
|
||||
#line 348 "toke.l"
|
||||
#line 347 "toke.l"
|
||||
{
|
||||
int n;
|
||||
|
||||
@ -2073,7 +2072,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 22:
|
||||
YY_RULE_SETUP
|
||||
#line 374 "toke.l"
|
||||
#line 373 "toke.l"
|
||||
{
|
||||
/* cmnd does not require passwd for this user */
|
||||
LEXTRACE("NOPASSWD ");
|
||||
@ -2082,7 +2081,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 23:
|
||||
YY_RULE_SETUP
|
||||
#line 380 "toke.l"
|
||||
#line 379 "toke.l"
|
||||
{
|
||||
/* cmnd requires passwd for this user */
|
||||
LEXTRACE("PASSWD ");
|
||||
@ -2091,7 +2090,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 24:
|
||||
YY_RULE_SETUP
|
||||
#line 386 "toke.l"
|
||||
#line 385 "toke.l"
|
||||
{
|
||||
LEXTRACE("NOEXEC ");
|
||||
LEXRETURN(NOEXEC);
|
||||
@ -2099,7 +2098,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 25:
|
||||
YY_RULE_SETUP
|
||||
#line 391 "toke.l"
|
||||
#line 390 "toke.l"
|
||||
{
|
||||
LEXTRACE("EXEC ");
|
||||
LEXRETURN(EXEC);
|
||||
@ -2107,7 +2106,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 26:
|
||||
YY_RULE_SETUP
|
||||
#line 396 "toke.l"
|
||||
#line 395 "toke.l"
|
||||
{
|
||||
LEXTRACE("SETENV ");
|
||||
LEXRETURN(SETENV);
|
||||
@ -2115,7 +2114,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 27:
|
||||
YY_RULE_SETUP
|
||||
#line 401 "toke.l"
|
||||
#line 400 "toke.l"
|
||||
{
|
||||
LEXTRACE("NOSETENV ");
|
||||
LEXRETURN(NOSETENV);
|
||||
@ -2123,7 +2122,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 28:
|
||||
YY_RULE_SETUP
|
||||
#line 406 "toke.l"
|
||||
#line 405 "toke.l"
|
||||
{
|
||||
LEXTRACE("LOG_OUTPUT ");
|
||||
LEXRETURN(LOG_OUTPUT);
|
||||
@ -2131,7 +2130,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 29:
|
||||
YY_RULE_SETUP
|
||||
#line 411 "toke.l"
|
||||
#line 410 "toke.l"
|
||||
{
|
||||
LEXTRACE("NOLOG_OUTPUT ");
|
||||
LEXRETURN(NOLOG_OUTPUT);
|
||||
@ -2139,7 +2138,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 30:
|
||||
YY_RULE_SETUP
|
||||
#line 416 "toke.l"
|
||||
#line 415 "toke.l"
|
||||
{
|
||||
LEXTRACE("LOG_INPUT ");
|
||||
LEXRETURN(LOG_INPUT);
|
||||
@ -2147,7 +2146,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 31:
|
||||
YY_RULE_SETUP
|
||||
#line 421 "toke.l"
|
||||
#line 420 "toke.l"
|
||||
{
|
||||
LEXTRACE("NOLOG_INPUT ");
|
||||
LEXRETURN(NOLOG_INPUT);
|
||||
@ -2155,7 +2154,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 32:
|
||||
YY_RULE_SETUP
|
||||
#line 426 "toke.l"
|
||||
#line 425 "toke.l"
|
||||
{
|
||||
/* empty group or netgroup */
|
||||
LEXTRACE("ERROR ");
|
||||
@ -2164,7 +2163,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 33:
|
||||
YY_RULE_SETUP
|
||||
#line 432 "toke.l"
|
||||
#line 431 "toke.l"
|
||||
{
|
||||
/* netgroup */
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
@ -2175,7 +2174,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 34:
|
||||
YY_RULE_SETUP
|
||||
#line 440 "toke.l"
|
||||
#line 439 "toke.l"
|
||||
{
|
||||
/* group */
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
@ -2186,7 +2185,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 35:
|
||||
YY_RULE_SETUP
|
||||
#line 448 "toke.l"
|
||||
#line 447 "toke.l"
|
||||
{
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
yyterminate();
|
||||
@ -2196,7 +2195,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 36:
|
||||
YY_RULE_SETUP
|
||||
#line 455 "toke.l"
|
||||
#line 454 "toke.l"
|
||||
{
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
yyterminate();
|
||||
@ -2206,7 +2205,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 37:
|
||||
YY_RULE_SETUP
|
||||
#line 462 "toke.l"
|
||||
#line 461 "toke.l"
|
||||
{
|
||||
if (!ipv6_valid(sudoerstext)) {
|
||||
LEXTRACE("ERROR ");
|
||||
@ -2220,7 +2219,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 38:
|
||||
YY_RULE_SETUP
|
||||
#line 473 "toke.l"
|
||||
#line 472 "toke.l"
|
||||
{
|
||||
if (!ipv6_valid(sudoerstext)) {
|
||||
LEXTRACE("ERROR ");
|
||||
@ -2234,7 +2233,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 39:
|
||||
YY_RULE_SETUP
|
||||
#line 484 "toke.l"
|
||||
#line 483 "toke.l"
|
||||
{
|
||||
LEXTRACE("ALL ");
|
||||
LEXRETURN(ALL);
|
||||
@ -2243,7 +2242,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 40:
|
||||
YY_RULE_SETUP
|
||||
#line 490 "toke.l"
|
||||
#line 489 "toke.l"
|
||||
{
|
||||
#ifdef HAVE_SELINUX
|
||||
LEXTRACE("ROLE ");
|
||||
@ -2255,7 +2254,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 41:
|
||||
YY_RULE_SETUP
|
||||
#line 499 "toke.l"
|
||||
#line 498 "toke.l"
|
||||
{
|
||||
#ifdef HAVE_SELINUX
|
||||
LEXTRACE("TYPE ");
|
||||
@ -2267,7 +2266,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 42:
|
||||
YY_RULE_SETUP
|
||||
#line 507 "toke.l"
|
||||
#line 506 "toke.l"
|
||||
{
|
||||
#ifdef HAVE_PRIV_SET
|
||||
LEXTRACE("PRIVS ");
|
||||
@ -2279,7 +2278,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 43:
|
||||
YY_RULE_SETUP
|
||||
#line 516 "toke.l"
|
||||
#line 515 "toke.l"
|
||||
{
|
||||
#ifdef HAVE_PRIV_SET
|
||||
LEXTRACE("LIMITPRIVS ");
|
||||
@ -2291,7 +2290,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 44:
|
||||
YY_RULE_SETUP
|
||||
#line 525 "toke.l"
|
||||
#line 524 "toke.l"
|
||||
{
|
||||
got_alias:
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
@ -2302,7 +2301,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 45:
|
||||
YY_RULE_SETUP
|
||||
#line 533 "toke.l"
|
||||
#line 532 "toke.l"
|
||||
{
|
||||
/* no command args allowed for Defaults!/path */
|
||||
if (!fill_cmnd(sudoerstext, sudoersleng))
|
||||
@ -2313,7 +2312,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 46:
|
||||
YY_RULE_SETUP
|
||||
#line 541 "toke.l"
|
||||
#line 540 "toke.l"
|
||||
{
|
||||
BEGIN GOTCMND;
|
||||
LEXTRACE("COMMAND ");
|
||||
@ -2323,7 +2322,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 47:
|
||||
YY_RULE_SETUP
|
||||
#line 548 "toke.l"
|
||||
#line 547 "toke.l"
|
||||
{
|
||||
/* directories can't have args... */
|
||||
if (sudoerstext[sudoersleng - 1] == '/') {
|
||||
@ -2341,7 +2340,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 48:
|
||||
YY_RULE_SETUP
|
||||
#line 563 "toke.l"
|
||||
#line 562 "toke.l"
|
||||
{
|
||||
LEXTRACE("BEGINSTR ");
|
||||
sudoerslval.string = NULL;
|
||||
@ -2351,7 +2350,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 49:
|
||||
YY_RULE_SETUP
|
||||
#line 570 "toke.l"
|
||||
#line 569 "toke.l"
|
||||
{
|
||||
/* a word */
|
||||
if (!fill(sudoerstext, sudoersleng))
|
||||
@ -2362,7 +2361,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 50:
|
||||
YY_RULE_SETUP
|
||||
#line 578 "toke.l"
|
||||
#line 577 "toke.l"
|
||||
{
|
||||
LEXTRACE("( ");
|
||||
LEXRETURN('(');
|
||||
@ -2370,7 +2369,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 51:
|
||||
YY_RULE_SETUP
|
||||
#line 583 "toke.l"
|
||||
#line 582 "toke.l"
|
||||
{
|
||||
LEXTRACE(") ");
|
||||
LEXRETURN(')');
|
||||
@ -2378,7 +2377,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 52:
|
||||
YY_RULE_SETUP
|
||||
#line 588 "toke.l"
|
||||
#line 587 "toke.l"
|
||||
{
|
||||
LEXTRACE(", ");
|
||||
LEXRETURN(',');
|
||||
@ -2386,7 +2385,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 53:
|
||||
YY_RULE_SETUP
|
||||
#line 593 "toke.l"
|
||||
#line 592 "toke.l"
|
||||
{
|
||||
LEXTRACE("= ");
|
||||
LEXRETURN('=');
|
||||
@ -2394,7 +2393,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 54:
|
||||
YY_RULE_SETUP
|
||||
#line 598 "toke.l"
|
||||
#line 597 "toke.l"
|
||||
{
|
||||
LEXTRACE(": ");
|
||||
LEXRETURN(':');
|
||||
@ -2402,7 +2401,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 55:
|
||||
YY_RULE_SETUP
|
||||
#line 603 "toke.l"
|
||||
#line 602 "toke.l"
|
||||
{
|
||||
if (sudoersleng & 1) {
|
||||
LEXTRACE("!");
|
||||
@ -2412,7 +2411,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 56:
|
||||
YY_RULE_SETUP
|
||||
#line 610 "toke.l"
|
||||
#line 609 "toke.l"
|
||||
{
|
||||
if (YY_START == INSTR) {
|
||||
LEXTRACE("ERROR ");
|
||||
@ -2427,14 +2426,14 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 57:
|
||||
YY_RULE_SETUP
|
||||
#line 622 "toke.l"
|
||||
#line 621 "toke.l"
|
||||
{ /* throw away space/tabs */
|
||||
sawspace = true; /* but remember for fill_args */
|
||||
}
|
||||
YY_BREAK
|
||||
case 58:
|
||||
YY_RULE_SETUP
|
||||
#line 626 "toke.l"
|
||||
#line 625 "toke.l"
|
||||
{
|
||||
sawspace = true; /* remember for fill_args */
|
||||
sudolineno++;
|
||||
@ -2443,7 +2442,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 59:
|
||||
YY_RULE_SETUP
|
||||
#line 632 "toke.l"
|
||||
#line 631 "toke.l"
|
||||
{
|
||||
BEGIN INITIAL;
|
||||
sudolineno++;
|
||||
@ -2454,7 +2453,7 @@ YY_RULE_SETUP
|
||||
YY_BREAK
|
||||
case 60:
|
||||
YY_RULE_SETUP
|
||||
#line 640 "toke.l"
|
||||
#line 639 "toke.l"
|
||||
{
|
||||
LEXTRACE("ERROR ");
|
||||
LEXRETURN(ERROR);
|
||||
@ -2466,7 +2465,7 @@ case YY_STATE_EOF(GOTCMND):
|
||||
case YY_STATE_EOF(STARTDEFS):
|
||||
case YY_STATE_EOF(INDEFS):
|
||||
case YY_STATE_EOF(INSTR):
|
||||
#line 645 "toke.l"
|
||||
#line 644 "toke.l"
|
||||
{
|
||||
if (YY_START != INITIAL) {
|
||||
BEGIN INITIAL;
|
||||
@ -2479,10 +2478,10 @@ case YY_STATE_EOF(INSTR):
|
||||
YY_BREAK
|
||||
case 61:
|
||||
YY_RULE_SETUP
|
||||
#line 655 "toke.l"
|
||||
#line 654 "toke.l"
|
||||
ECHO;
|
||||
YY_BREAK
|
||||
#line 2485 "lex.sudoers.c"
|
||||
#line 2484 "lex.sudoers.c"
|
||||
|
||||
case YY_END_OF_BUFFER:
|
||||
{
|
||||
@ -3373,7 +3372,7 @@ int main()
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
#line 655 "toke.l"
|
||||
#line 654 "toke.l"
|
||||
|
||||
struct path_list {
|
||||
char *path;
|
||||
|
@ -26,7 +26,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -25,7 +25,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -24,7 +24,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -32,7 +32,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/socket.h>
|
||||
#include <sys/time.h>
|
||||
@ -68,7 +67,6 @@
|
||||
#include <fcntl.h>
|
||||
#include <netinet/in.h>
|
||||
#include <arpa/inet.h>
|
||||
#include <netdb.h>
|
||||
#if TIME_WITH_SYS_TIME
|
||||
# include <time.h>
|
||||
#endif
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
|
||||
#include <stdio.h>
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#ifdef HAVE_SYS_SYSMACROS_H
|
||||
# include <sys/sysmacros.h>
|
||||
#endif
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#ifdef HAVE_SYS_SYSMACROS_H
|
||||
# include <sys/sysmacros.h>
|
||||
#endif
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/ioctl.h>
|
||||
#ifdef HAVE_SYS_STROPTS_H
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -32,7 +32,6 @@ struct rtentry;
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/socket.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/ioctl.h>
|
||||
#if defined(HAVE_SYS_SOCKIO_H) && !defined(SIOCGIFCONF)
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
|
@ -21,7 +21,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/wait.h>
|
||||
#include <sys/socket.h>
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/wait.h>
|
||||
|
@ -26,7 +26,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <stdio.h>
|
||||
#ifdef STDC_HEADERS
|
||||
# include <stdlib.h>
|
||||
|
@ -23,7 +23,6 @@
|
||||
#endif
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/stat.h>
|
||||
#if defined(MAJOR_IN_MKDEV)
|
||||
# include <sys/mkdev.h>
|
||||
@ -71,8 +70,10 @@
|
||||
# endif
|
||||
#endif
|
||||
#if defined(HAVE_STRUCT_KINFO_PROC_P_TDEV) || defined (HAVE_STRUCT_KINFO_PROC_KP_EPROC_E_TDEV) || defined(HAVE_STRUCT_KINFO_PROC2_P_TDEV)
|
||||
# include <sys/param.h>
|
||||
# include <sys/sysctl.h>
|
||||
#elif defined(HAVE_STRUCT_KINFO_PROC_KI_TDEV)
|
||||
# include <sys/param.h>
|
||||
# include <sys/sysctl.h>
|
||||
# include <sys/user.h>
|
||||
#endif
|
||||
|
@ -17,7 +17,6 @@
|
||||
#include <config.h>
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/param.h>
|
||||
#include <sys/time.h>
|
||||
#include <sys/wait.h>
|
||||
#include <stdio.h>
|
||||
|
Loading…
x
Reference in New Issue
Block a user