Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.busybox.net/busybox.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2023-06-15 12:55:56 +0300
committerDenys Vlasenko <vda.linux@googlemail.com>2023-06-15 12:55:56 +0300
commit648f506949ded749e28186d0092b6e42085c897b (patch)
tree049c72bc8149f41fc617d00f7d32f1d6384f8e2f /miscutils
parent61a4959251667751e424e600c6cb75de39d6b1c3 (diff)
libbb: code shrink: introduce and use [_]exit_FAILURE()
function old new delta exit_FAILURE - 7 +7 _exit_FAILURE - 7 +7 run 198 199 +1 restore_state_and_exit 114 115 +1 xbsd_write_bootstrap 399 397 -2 vfork_compressor 209 207 -2 sig_handler 12 10 -2 serial_ctl 154 152 -2 parse_args 1169 1167 -2 onintr 21 19 -2 make_new_session 493 491 -2 login_main 988 986 -2 gotsig 35 33 -2 do_iplink 1315 1313 -2 addgroup_main 397 395 -2 inetd_main 1911 1908 -3 ------------------------------------------------------------------------------ (add/remove: 2/0 grow/shrink: 2/12 up/down: 16/-25) Total: -9 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'miscutils')
-rw-r--r--miscutils/devfsd.c6
-rw-r--r--miscutils/setserial.c2
2 files changed, 4 insertions, 4 deletions
diff --git a/miscutils/devfsd.c b/miscutils/devfsd.c
index 297693f8c..36b491595 100644
--- a/miscutils/devfsd.c
+++ b/miscutils/devfsd.c
@@ -354,10 +354,10 @@ static const char bb_msg_variable_not_found[] ALIGN1 = "variable: %s not found";
#define simple_info_logger(p, msg)
#define msg_logger(p, fmt, args...)
#define simple_msg_logger(p, msg)
-#define msg_logger_and_die(p, fmt, args...) exit(EXIT_FAILURE)
-#define simple_msg_logger_and_die(p, msg) exit(EXIT_FAILURE)
+#define msg_logger_and_die(p, fmt, args...) exit_FAILURE()
+#define simple_msg_logger_and_die(p, msg) exit_FAILURE()
#define error_logger(p, fmt, args...)
-#define error_logger_and_die(p, fmt, args...) exit(EXIT_FAILURE)
+#define error_logger_and_die(p, fmt, args...) exit_FAILURE()
#endif
static void safe_memcpy(char *dest, const char *src, int len)
diff --git a/miscutils/setserial.c b/miscutils/setserial.c
index 2006861e2..175c788fc 100644
--- a/miscutils/setserial.c
+++ b/miscutils/setserial.c
@@ -535,7 +535,7 @@ static int serial_ctl(int fd, int ops, struct serial_struct *serinfo)
bb_simple_perror_msg(err);
if (ops & CTL_NODIE)
goto nodie;
- exit(EXIT_FAILURE);
+ exit_FAILURE();
}
static void print_flag(const char **prefix, const char *flag)