2016-09-16 13:10:58 +02:00
|
|
|
---
|
2019-01-09 14:08:47 +01:00
|
|
|
examples/loadables/finfo.c | 9 ++++-----
|
2016-09-16 13:10:58 +02:00
|
|
|
examples/loadables/head.c | 2 --
|
|
|
|
examples/loadables/id.c | 2 --
|
|
|
|
examples/loadables/mkdir.c | 2 +-
|
|
|
|
examples/loadables/pathchk.c | 2 --
|
|
|
|
examples/loadables/print.c | 2 +-
|
|
|
|
examples/loadables/tee.c | 2 --
|
2019-01-09 14:08:47 +01:00
|
|
|
7 files changed, 6 insertions(+), 15 deletions(-)
|
2016-09-16 13:10:58 +02:00
|
|
|
|
2010-02-18 12:17:29 +01:00
|
|
|
--- examples/loadables/finfo.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/finfo.c 2018-09-20 08:07:43.739129083 +0000
|
2016-09-16 13:10:58 +02:00
|
|
|
@@ -102,7 +102,7 @@ int argc;
|
2006-12-15 18:03:59 +01:00
|
|
|
char **argv;
|
|
|
|
{
|
|
|
|
register int i;
|
|
|
|
- int mode, flags, opt;
|
|
|
|
+ int flags, opt;
|
|
|
|
|
|
|
|
sh_optind = 0; /* XXX */
|
|
|
|
prog = base_pathname(argv[0]);
|
2016-09-16 13:10:58 +02:00
|
|
|
@@ -334,13 +334,13 @@ int flags;
|
2006-12-15 18:03:59 +01:00
|
|
|
else
|
|
|
|
printf("%ld\n", st->st_ctime);
|
|
|
|
} else if (flags & OPT_DEV)
|
|
|
|
- printf("%d\n", st->st_dev);
|
2019-01-09 14:08:47 +01:00
|
|
|
+ printf("%lu\n", (unsigned long)st->st_dev);
|
2006-12-15 18:03:59 +01:00
|
|
|
else if (flags & OPT_INO)
|
2019-01-09 14:08:47 +01:00
|
|
|
printf("%lu\n", (unsigned long)st->st_ino);
|
2006-12-15 18:03:59 +01:00
|
|
|
else if (flags & OPT_FID)
|
2019-01-09 14:08:47 +01:00
|
|
|
- printf("%d:%lu\n", st->st_dev, (unsigned long)st->st_ino);
|
|
|
|
+ printf("%lu:%lu\n", (unsigned long)st->st_dev, (unsigned long)st->st_ino);
|
2006-12-15 18:03:59 +01:00
|
|
|
else if (flags & OPT_NLINK)
|
|
|
|
- printf("%d\n", st->st_nlink);
|
2019-01-09 14:08:47 +01:00
|
|
|
+ printf("%lu\n", (unsigned long)st->st_nlink);
|
2006-12-15 18:03:59 +01:00
|
|
|
else if (flags & OPT_LNKNAM) {
|
|
|
|
#ifdef S_ISLNK
|
|
|
|
b = xmalloc(4096);
|
2016-09-16 13:10:58 +02:00
|
|
|
@@ -390,7 +390,6 @@ finfo_builtin(list)
|
2006-12-15 18:03:59 +01:00
|
|
|
{
|
|
|
|
int c, r;
|
|
|
|
char **v;
|
|
|
|
- WORD_LIST *l;
|
|
|
|
|
|
|
|
v = make_builtin_argv (list, &c);
|
|
|
|
r = finfo_main (c, v);
|
2010-02-18 12:17:29 +01:00
|
|
|
--- examples/loadables/head.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/head.c 2018-09-20 08:07:43.739129083 +0000
|
2016-09-16 13:10:58 +02:00
|
|
|
@@ -99,8 +99,6 @@ head_builtin (list)
|
2006-12-15 18:03:59 +01:00
|
|
|
WORD_LIST *l;
|
|
|
|
FILE *fp;
|
|
|
|
|
|
|
|
- char *t;
|
|
|
|
-
|
|
|
|
munge_list (list); /* change -num into -n num */
|
|
|
|
|
|
|
|
reset_internal_getopt ();
|
2010-02-18 12:17:29 +01:00
|
|
|
--- examples/loadables/id.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/id.c 2018-09-20 08:07:43.739129083 +0000
|
2015-03-19 12:47:55 +01:00
|
|
|
@@ -64,8 +64,6 @@ static int id_flags;
|
2006-12-15 18:03:59 +01:00
|
|
|
static uid_t ruid, euid;
|
|
|
|
static gid_t rgid, egid;
|
|
|
|
|
|
|
|
-static char *id_user;
|
|
|
|
-
|
|
|
|
static int inituser ();
|
|
|
|
|
|
|
|
static int id_pruser ();
|
2015-03-19 12:47:55 +01:00
|
|
|
--- examples/loadables/mkdir.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/mkdir.c 2018-09-20 08:07:43.739129083 +0000
|
|
|
|
@@ -170,7 +170,7 @@ make_path (path, nmode, parent_mode)
|
2006-12-15 18:03:59 +01:00
|
|
|
while (*p == '/')
|
|
|
|
p++;
|
|
|
|
|
|
|
|
- while (p = strchr (p, '/'))
|
|
|
|
+ while ((p = strchr (p, '/')))
|
|
|
|
{
|
|
|
|
*p = '\0';
|
|
|
|
if (stat (npath, &sb) != 0)
|
2010-02-18 12:17:29 +01:00
|
|
|
--- examples/loadables/pathchk.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/pathchk.c 2018-09-20 08:07:43.739129083 +0000
|
|
|
|
@@ -292,10 +292,8 @@ validate_path (path, portability)
|
2006-12-15 18:03:59 +01:00
|
|
|
if (*path == '\0')
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
-#ifdef lint
|
|
|
|
/* Suppress `used before initialized' warning. */
|
|
|
|
exists = 0;
|
|
|
|
-#endif
|
|
|
|
|
|
|
|
/* Figure out the parent of the first element in PATH. */
|
|
|
|
parent = xstrdup (*path == '/' ? "/" : ".");
|
2010-02-18 12:17:29 +01:00
|
|
|
--- examples/loadables/print.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/print.c 2018-09-20 08:07:43.739129083 +0000
|
2015-03-19 12:47:55 +01:00
|
|
|
@@ -77,7 +77,7 @@ print_builtin (list)
|
2006-12-15 18:03:59 +01:00
|
|
|
{
|
|
|
|
int c, r, nflag, raw, ofd, sflag;
|
|
|
|
intmax_t lfd;
|
|
|
|
- char **v, *pfmt, *arg;
|
|
|
|
+ char *pfmt;
|
|
|
|
WORD_LIST *l;
|
|
|
|
|
|
|
|
nflag = raw = sflag = 0;
|
2010-02-18 12:17:29 +01:00
|
|
|
--- examples/loadables/tee.c
|
2019-01-09 14:08:47 +01:00
|
|
|
+++ examples/loadables/tee.c 2018-09-20 08:07:43.739129083 +0000
|
2016-09-16 13:10:58 +02:00
|
|
|
@@ -70,8 +70,6 @@ tee_builtin (list)
|
2006-12-15 18:03:59 +01:00
|
|
|
FLIST *fl;
|
|
|
|
char *buf, *bp;
|
|
|
|
|
|
|
|
- char *t;
|
|
|
|
-
|
|
|
|
reset_internal_getopt ();
|
|
|
|
append = nointr = 0;
|
|
|
|
tee_flist = (FLIST *)NULL;
|