mirror of
https://github.com/topjohnwu/ndk-busybox.git
synced 2024-11-24 04:09:43 +00:00
Clear up some ambiguity with old style assignments.
-Erik
This commit is contained in:
parent
a6d0dbc86f
commit
04e97024e7
@ -27,8 +27,8 @@
|
||||
#include "internal.h"
|
||||
|
||||
|
||||
static uid_t uid=-1;
|
||||
static gid_t gid=-1;
|
||||
static uid_t uid = -1;
|
||||
static gid_t gid = -1;
|
||||
static int whichApp;
|
||||
static char* invocationName=NULL;
|
||||
static char* theMode=NULL;
|
||||
@ -92,7 +92,7 @@ int chmod_chown_chgrp_main(int argc, char **argv)
|
||||
|
||||
if (argc < 2)
|
||||
usage( appUsage);
|
||||
invocationName=*argv;
|
||||
invocationName = *argv;
|
||||
argc--;
|
||||
argv++;
|
||||
|
||||
@ -111,7 +111,7 @@ int chmod_chown_chgrp_main(int argc, char **argv)
|
||||
}
|
||||
|
||||
if ( whichApp == CHMOD_APP ) {
|
||||
theMode=*argv;
|
||||
theMode = *argv;
|
||||
} else {
|
||||
|
||||
/* Find the selected group */
|
||||
|
@ -204,10 +204,10 @@ date_main(int argc, char * * argv)
|
||||
}
|
||||
} else {
|
||||
if ( (date_fmt == NULL) && (strcmp(*argv, "+")==0) )
|
||||
date_fmt=*argv;
|
||||
date_fmt = *argv;
|
||||
else if (date_str == NULL) {
|
||||
set_time = 1;
|
||||
date_str=*argv;
|
||||
date_str = *argv;
|
||||
} else {
|
||||
usage ( date_usage);
|
||||
}
|
||||
|
4
date.c
4
date.c
@ -204,10 +204,10 @@ date_main(int argc, char * * argv)
|
||||
}
|
||||
} else {
|
||||
if ( (date_fmt == NULL) && (strcmp(*argv, "+")==0) )
|
||||
date_fmt=*argv;
|
||||
date_fmt = *argv;
|
||||
else if (date_str == NULL) {
|
||||
set_time = 1;
|
||||
date_str=*argv;
|
||||
date_str = *argv;
|
||||
} else {
|
||||
usage ( date_usage);
|
||||
}
|
||||
|
6
find.c
6
find.c
@ -70,7 +70,7 @@ int find_main(int argc, char **argv)
|
||||
argv++;
|
||||
|
||||
if ( argc > 0 && **argv != '-') {
|
||||
directory=*argv;
|
||||
directory = *argv;
|
||||
argc--;
|
||||
argv++;
|
||||
}
|
||||
@ -89,8 +89,8 @@ int find_main(int argc, char **argv)
|
||||
case 'n':
|
||||
if (strcmp(*argv, "name")==0) {
|
||||
if (argc-- > 1) {
|
||||
pattern=*(++argv);
|
||||
stopit=-TRUE;
|
||||
pattern = *(++argv);
|
||||
stopit=TRUE;
|
||||
} else {
|
||||
usage (find_usage);
|
||||
}
|
||||
|
@ -70,7 +70,7 @@ int find_main(int argc, char **argv)
|
||||
argv++;
|
||||
|
||||
if ( argc > 0 && **argv != '-') {
|
||||
directory=*argv;
|
||||
directory = *argv;
|
||||
argc--;
|
||||
argv++;
|
||||
}
|
||||
@ -89,8 +89,8 @@ int find_main(int argc, char **argv)
|
||||
case 'n':
|
||||
if (strcmp(*argv, "name")==0) {
|
||||
if (argc-- > 1) {
|
||||
pattern=*(++argv);
|
||||
stopit=-TRUE;
|
||||
pattern = *(++argv);
|
||||
stopit=TRUE;
|
||||
} else {
|
||||
usage (find_usage);
|
||||
}
|
||||
|
4
init.c
4
init.c
@ -154,7 +154,7 @@ void message(int device, char *fmt, ...)
|
||||
}
|
||||
|
||||
#else
|
||||
static int log_fd=-1;
|
||||
static int log_fd = -1;
|
||||
|
||||
/* Take full control of the log tty, and never close it.
|
||||
* It's mine, all mine! Muhahahaha! */
|
||||
@ -166,7 +166,7 @@ void message(int device, char *fmt, ...)
|
||||
device = CONSOLE;
|
||||
}
|
||||
else if ((log_fd = device_open(log, O_RDWR|O_NDELAY)) < 0) {
|
||||
log_fd=-1;
|
||||
log_fd = -1;
|
||||
fprintf(stderr, "Bummer, can't write to log on %s!\r\n", log);
|
||||
fflush(stderr);
|
||||
return;
|
||||
|
@ -154,7 +154,7 @@ void message(int device, char *fmt, ...)
|
||||
}
|
||||
|
||||
#else
|
||||
static int log_fd=-1;
|
||||
static int log_fd = -1;
|
||||
|
||||
/* Take full control of the log tty, and never close it.
|
||||
* It's mine, all mine! Muhahahaha! */
|
||||
@ -166,7 +166,7 @@ void message(int device, char *fmt, ...)
|
||||
device = CONSOLE;
|
||||
}
|
||||
else if ((log_fd = device_open(log, O_RDWR|O_NDELAY)) < 0) {
|
||||
log_fd=-1;
|
||||
log_fd = -1;
|
||||
fprintf(stderr, "Bummer, can't write to log on %s!\r\n", log);
|
||||
fflush(stderr);
|
||||
return;
|
||||
|
2
logger.c
2
logger.c
@ -161,7 +161,7 @@ extern int logger_main(int argc, char **argv)
|
||||
message=buf;
|
||||
} else {
|
||||
if (argc>=1) {
|
||||
message=*argv;
|
||||
message = *argv;
|
||||
} else {
|
||||
fprintf(stderr, "No message\n");
|
||||
exit( FALSE);
|
||||
|
4
mount.c
4
mount.c
@ -354,9 +354,9 @@ extern int mount_main (int argc, char **argv)
|
||||
}
|
||||
} else {
|
||||
if (device == NULL)
|
||||
device=*argv;
|
||||
device = *argv;
|
||||
else if (directory == NULL)
|
||||
directory=*argv;
|
||||
directory = *argv;
|
||||
else {
|
||||
goto goodbye;
|
||||
}
|
||||
|
@ -161,7 +161,7 @@ extern int logger_main(int argc, char **argv)
|
||||
message=buf;
|
||||
} else {
|
||||
if (argc>=1) {
|
||||
message=*argv;
|
||||
message = *argv;
|
||||
} else {
|
||||
fprintf(stderr, "No message\n");
|
||||
exit( FALSE);
|
||||
|
@ -354,9 +354,9 @@ extern int mount_main (int argc, char **argv)
|
||||
}
|
||||
} else {
|
||||
if (device == NULL)
|
||||
device=*argv;
|
||||
device = *argv;
|
||||
else if (directory == NULL)
|
||||
directory=*argv;
|
||||
directory = *argv;
|
||||
else {
|
||||
goto goodbye;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user