Move applet_name declaration from busybox.h to libbb.h.

This commit is contained in:
Matt Kraai 2001-04-24 01:12:33 +00:00
parent af030496fa
commit 9ff9325e60
7 changed files with 5 additions and 9 deletions

View File

@ -66,8 +66,6 @@ extern const struct BB_applet applets[];
#include "applets.h"
#undef PROTOTYPES
extern const char *applet_name;
#ifdef BB_FEATURE_BUFFERS_GO_ON_STACK
#define RESERVE_BB_BUFFER(buffer,len) char buffer[len]
#define RESERVE_BB_UBUFFER(buffer,len) unsigned char buffer[len]

View File

@ -66,8 +66,6 @@ extern const struct BB_applet applets[];
#include "applets.h"
#undef PROTOTYPES
extern const char *applet_name;
#ifdef BB_FEATURE_BUFFERS_GO_ON_STACK
#define RESERVE_BB_BUFFER(buffer,len) char buffer[len]
#define RESERVE_BB_UBUFFER(buffer,len) unsigned char buffer[len]

View File

@ -262,4 +262,6 @@ enum {
CP_INTERACTIVE = 16
};
extern const char *applet_name;
#endif /* __LIBBB_H__ */

View File

@ -126,7 +126,7 @@ int copy_file(const char *source, const char *dest, int flags)
if (dest_exists) {
if (flags & CP_INTERACTIVE) {
fprintf(stderr, "cp: overwrite `%s'? ", dest);
fprintf(stderr, "%s: overwrite `%s'? ", applet_name, dest);
if (!ask_confirmation())
return 0;
}

View File

@ -262,4 +262,6 @@ enum {
CP_INTERACTIVE = 16
};
extern const char *applet_name;
#endif /* __LIBBB_H__ */

View File

@ -29,8 +29,6 @@
#include <sys/syslog.h>
#include "libbb.h"
extern const char *applet_name;
void syslog_msg_with_name(const char *name, int facility, int pri, const char *msg)
{
openlog(name, 0, facility);

View File

@ -31,8 +31,6 @@
#include <stdlib.h>
#include "libbb.h"
extern const char *applet_name;
extern void verror_msg(const char *s, va_list p)
{
fflush(stdout);