mirror of
https://github.com/sheumann/hush.git
synced 2024-06-27 08:29:33 +00:00
Robert P. Day removed 8 gazillion occurrences of "extern" on function
definitions. (That should only be on prototypes.)
This commit is contained in:
parent
1f5e25bf3e
commit
dfba741457
|
@ -405,7 +405,7 @@ static void check_suid (struct BB_applet *applet)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
extern void bb_show_usage (void)
|
void bb_show_usage (void)
|
||||||
{
|
{
|
||||||
const char *format_string;
|
const char *format_string;
|
||||||
const char *usage_string = usage_messages;
|
const char *usage_string = usage_messages;
|
||||||
|
|
|
@ -57,7 +57,7 @@ static void header_verbose_list_ar(const file_header_t *file_header)
|
||||||
#define AR_OPT_CREATE 0x20
|
#define AR_OPT_CREATE 0x20
|
||||||
#define AR_OPT_INSERT 0x40
|
#define AR_OPT_INSERT 0x40
|
||||||
|
|
||||||
extern int ar_main(int argc, char **argv)
|
int ar_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
archive_handle_t *archive_handle;
|
archive_handle_t *archive_handle;
|
||||||
unsigned long opt;
|
unsigned long opt;
|
||||||
|
|
|
@ -38,7 +38,7 @@
|
||||||
#define CPIO_OPT_CREATE_LEADING_DIR 0x20
|
#define CPIO_OPT_CREATE_LEADING_DIR 0x20
|
||||||
#define CPIO_OPT_PRESERVE_MTIME 0x40
|
#define CPIO_OPT_PRESERVE_MTIME 0x40
|
||||||
|
|
||||||
extern int cpio_main(int argc, char **argv)
|
int cpio_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
archive_handle_t *archive_handle;
|
archive_handle_t *archive_handle;
|
||||||
char *cpio_filename = NULL;
|
char *cpio_filename = NULL;
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#define DPKG_DEB_OPT_EXTRACT 8
|
#define DPKG_DEB_OPT_EXTRACT 8
|
||||||
#define DPKG_DEB_OPT_EXTRACT_VERBOSE 16
|
#define DPKG_DEB_OPT_EXTRACT_VERBOSE 16
|
||||||
|
|
||||||
extern int dpkg_deb_main(int argc, char **argv)
|
int dpkg_deb_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
archive_handle_t *ar_archive;
|
archive_handle_t *ar_archive;
|
||||||
archive_handle_t *tar_archive;
|
archive_handle_t *tar_archive;
|
||||||
|
|
|
@ -75,7 +75,7 @@ static char *license_msg[] = {
|
||||||
#define GUNZIP_OPT_TEST 4
|
#define GUNZIP_OPT_TEST 4
|
||||||
#define GUNZIP_OPT_DECOMPRESS 8
|
#define GUNZIP_OPT_DECOMPRESS 8
|
||||||
|
|
||||||
extern int gunzip_main(int argc, char **argv)
|
int gunzip_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
char status = EXIT_SUCCESS;
|
char status = EXIT_SUCCESS;
|
||||||
unsigned long opt;
|
unsigned long opt;
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern void archive_xread_all(const archive_handle_t *archive_handle, void *buf, const size_t count)
|
void archive_xread_all(const archive_handle_t *archive_handle, void *buf, const size_t count)
|
||||||
{
|
{
|
||||||
ssize_t size;
|
ssize_t size;
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern ssize_t archive_xread_all_eof(archive_handle_t *archive_handle, unsigned char *buf, size_t count)
|
ssize_t archive_xread_all_eof(archive_handle_t *archive_handle, unsigned char *buf, size_t count)
|
||||||
{
|
{
|
||||||
ssize_t size;
|
ssize_t size;
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h" /* for external decl of check_header_gzip */
|
#include "unarchive.h" /* for external decl of check_header_gzip */
|
||||||
|
|
||||||
extern void check_header_gzip(int src_fd)
|
void check_header_gzip(int src_fd)
|
||||||
{
|
{
|
||||||
union {
|
union {
|
||||||
unsigned char raw[8];
|
unsigned char raw[8];
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void data_align(archive_handle_t *archive_handle, const unsigned short boundary)
|
void data_align(archive_handle_t *archive_handle, const unsigned short boundary)
|
||||||
{
|
{
|
||||||
const unsigned short skip_amount = (boundary - (archive_handle->offset % boundary)) % boundary;
|
const unsigned short skip_amount = (boundary - (archive_handle->offset % boundary)) % boundary;
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void data_extract_all(archive_handle_t *archive_handle)
|
void data_extract_all(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
file_header_t *file_header = archive_handle->file_header;
|
file_header_t *file_header = archive_handle->file_header;
|
||||||
int dst_fd;
|
int dst_fd;
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void data_extract_to_buffer(archive_handle_t *archive_handle)
|
void data_extract_to_buffer(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
const unsigned int size = archive_handle->file_header->size;
|
const unsigned int size = archive_handle->file_header->size;
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
|
|
||||||
extern void data_extract_to_stdout(archive_handle_t *archive_handle)
|
void data_extract_to_stdout(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
bb_copyfd_size(archive_handle->src_fd, STDOUT_FILENO, archive_handle->file_header->size);
|
bb_copyfd_size(archive_handle->src_fd, STDOUT_FILENO, archive_handle->file_header->size);
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern void data_skip(archive_handle_t *archive_handle)
|
void data_skip(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
archive_handle->seek(archive_handle, archive_handle->file_header->size);
|
archive_handle->seek(archive_handle, archive_handle->file_header->size);
|
||||||
}
|
}
|
||||||
|
|
|
@ -684,7 +684,7 @@ static int start_bunzip(bunzip_data **bdp, int in_fd, unsigned char *inbuf,
|
||||||
/* Example usage: decompress src_fd to dst_fd. (Stops at end of bzip data,
|
/* Example usage: decompress src_fd to dst_fd. (Stops at end of bzip data,
|
||||||
not end of file.) */
|
not end of file.) */
|
||||||
|
|
||||||
extern int uncompressStream(int src_fd, int dst_fd)
|
int uncompressStream(int src_fd, int dst_fd)
|
||||||
{
|
{
|
||||||
char *outbuf;
|
char *outbuf;
|
||||||
bunzip_data *bd;
|
bunzip_data *bd;
|
||||||
|
|
|
@ -95,7 +95,7 @@ static unsigned short codetab[HSIZE];
|
||||||
* with those of the compress() routine. See the definitions above.
|
* with those of the compress() routine. See the definitions above.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
extern int uncompress(int fd_in, int fd_out)
|
int uncompress(int fd_in, int fd_out)
|
||||||
{
|
{
|
||||||
unsigned char *stackp;
|
unsigned char *stackp;
|
||||||
long int code;
|
long int code;
|
||||||
|
|
|
@ -892,7 +892,7 @@ static int inflate_get_next_window(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Initialise bytebuffer, be careful not to overfill the buffer */
|
/* Initialise bytebuffer, be careful not to overfill the buffer */
|
||||||
extern void inflate_init(unsigned int bufsize)
|
void inflate_init(unsigned int bufsize)
|
||||||
{
|
{
|
||||||
/* Set the bytebuffer size, default is same as gunzip_wsize */
|
/* Set the bytebuffer size, default is same as gunzip_wsize */
|
||||||
bytebuffer_max = bufsize + 8;
|
bytebuffer_max = bufsize + 8;
|
||||||
|
@ -900,12 +900,12 @@ extern void inflate_init(unsigned int bufsize)
|
||||||
bytebuffer_size = 0;
|
bytebuffer_size = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern void inflate_cleanup(void)
|
void inflate_cleanup(void)
|
||||||
{
|
{
|
||||||
free(bytebuffer);
|
free(bytebuffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int inflate_unzip(int in, int out)
|
int inflate_unzip(int in, int out)
|
||||||
{
|
{
|
||||||
ssize_t nwrote;
|
ssize_t nwrote;
|
||||||
typedef void (*sig_type) (int);
|
typedef void (*sig_type) (int);
|
||||||
|
@ -952,7 +952,7 @@ extern int inflate_unzip(int in, int out)
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int inflate_gunzip(int in, int out)
|
int inflate_gunzip(int in, int out)
|
||||||
{
|
{
|
||||||
unsigned int stored_crc = 0;
|
unsigned int stored_crc = 0;
|
||||||
unsigned int count;
|
unsigned int count;
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
/* Accept any non-null name, its not really a filter at all */
|
/* Accept any non-null name, its not really a filter at all */
|
||||||
extern char filter_accept_all(archive_handle_t *archive_handle)
|
char filter_accept_all(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
if (archive_handle->file_header->name) {
|
if (archive_handle->file_header->name) {
|
||||||
return(EXIT_SUCCESS);
|
return(EXIT_SUCCESS);
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
/*
|
/*
|
||||||
* Accept names that are in the accept list, ignoring reject list.
|
* Accept names that are in the accept list, ignoring reject list.
|
||||||
*/
|
*/
|
||||||
extern char filter_accept_list(archive_handle_t *archive_handle)
|
char filter_accept_list(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
if (find_list_entry(archive_handle->accept, archive_handle->file_header->name)) {
|
if (find_list_entry(archive_handle->accept, archive_handle->file_header->name)) {
|
||||||
return(EXIT_SUCCESS);
|
return(EXIT_SUCCESS);
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
* e.g. if its a .tar.gz modify archive_handle->sub_archive to process a .tar.gz
|
* e.g. if its a .tar.gz modify archive_handle->sub_archive to process a .tar.gz
|
||||||
* or if its a .tar.bz2 make archive_handle->sub_archive handle that
|
* or if its a .tar.bz2 make archive_handle->sub_archive handle that
|
||||||
*/
|
*/
|
||||||
extern char filter_accept_list_reassign(archive_handle_t *archive_handle)
|
char filter_accept_list_reassign(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
/* Check the file entry is in the accept list */
|
/* Check the file entry is in the accept list */
|
||||||
if (find_list_entry(archive_handle->accept, archive_handle->file_header->name)) {
|
if (find_list_entry(archive_handle->accept, archive_handle->file_header->name)) {
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
/*
|
/*
|
||||||
* Accept names that are in the accept list and not in the reject list
|
* Accept names that are in the accept list and not in the reject list
|
||||||
*/
|
*/
|
||||||
extern char filter_accept_reject_list(archive_handle_t *archive_handle)
|
char filter_accept_reject_list(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
const char *key = archive_handle->file_header->name;
|
const char *key = archive_handle->file_header->name;
|
||||||
const llist_t *accept_entry = find_list_entry(archive_handle->accept, key);
|
const llist_t *accept_entry = find_list_entry(archive_handle->accept, key);
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern const llist_t *find_list_entry(const llist_t *list, const char *filename)
|
const llist_t *find_list_entry(const llist_t *list, const char *filename)
|
||||||
{
|
{
|
||||||
while (list) {
|
while (list) {
|
||||||
if (fnmatch(list->data, filename, 0) == 0) {
|
if (fnmatch(list->data, filename, 0) == 0) {
|
||||||
|
|
|
@ -21,7 +21,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern char get_header_ar(archive_handle_t *archive_handle)
|
char get_header_ar(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
file_header_t *typed = archive_handle->file_header;
|
file_header_t *typed = archive_handle->file_header;
|
||||||
union {
|
union {
|
||||||
|
|
|
@ -28,7 +28,7 @@ typedef struct hardlinks_s {
|
||||||
struct hardlinks_s *next;
|
struct hardlinks_s *next;
|
||||||
} hardlinks_t;
|
} hardlinks_t;
|
||||||
|
|
||||||
extern char get_header_cpio(archive_handle_t *archive_handle)
|
char get_header_cpio(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
static hardlinks_t *saved_hardlinks = NULL;
|
static hardlinks_t *saved_hardlinks = NULL;
|
||||||
static unsigned short pending_hardlinks = 0;
|
static unsigned short pending_hardlinks = 0;
|
||||||
|
|
|
@ -22,7 +22,7 @@ static char *longname = NULL;
|
||||||
static char *linkname = NULL;
|
static char *linkname = NULL;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern char get_header_tar(archive_handle_t *archive_handle)
|
char get_header_tar(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
file_header_t *file_header = archive_handle->file_header;
|
file_header_t *file_header = archive_handle->file_header;
|
||||||
union {
|
union {
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern char get_header_tar_bz2(archive_handle_t *archive_handle)
|
char get_header_tar_bz2(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
/* Cant lseek over pipe's */
|
/* Cant lseek over pipe's */
|
||||||
archive_handle->seek = seek_by_char;
|
archive_handle->seek = seek_by_char;
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern char get_header_tar_gz(archive_handle_t *archive_handle)
|
char get_header_tar_gz(archive_handle_t *archive_handle)
|
||||||
{
|
{
|
||||||
unsigned char magic[2];
|
unsigned char magic[2];
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void header_list(const file_header_t *file_header)
|
void header_list(const file_header_t *file_header)
|
||||||
{
|
{
|
||||||
puts(file_header->name);
|
puts(file_header->name);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void header_skip(const file_header_t *file_header ATTRIBUTE_UNUSED)
|
void header_skip(const file_header_t *file_header ATTRIBUTE_UNUSED)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void header_verbose_list(const file_header_t *file_header)
|
void header_verbose_list(const file_header_t *file_header)
|
||||||
{
|
{
|
||||||
struct tm *mtime = localtime(&(file_header->mtime));
|
struct tm *mtime = localtime(&(file_header->mtime));
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
/* transformer(), more than meets the eye */
|
/* transformer(), more than meets the eye */
|
||||||
extern int open_transformer(int src_fd, int (*transformer)(int src_fd, int dst_fd))
|
int open_transformer(int src_fd, int (*transformer)(int src_fd, int dst_fd))
|
||||||
{
|
{
|
||||||
int fd_pipe[2];
|
int fd_pipe[2];
|
||||||
int pid;
|
int pid;
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
*
|
*
|
||||||
* TODO: rename to seek_by_read
|
* TODO: rename to seek_by_read
|
||||||
*/
|
*/
|
||||||
extern void seek_by_char(const archive_handle_t *archive_handle, const unsigned int jump_size)
|
void seek_by_char(const archive_handle_t *archive_handle, const unsigned int jump_size)
|
||||||
{
|
{
|
||||||
if (jump_size) {
|
if (jump_size) {
|
||||||
bb_copyfd_size(archive_handle->src_fd, -1, jump_size);
|
bb_copyfd_size(archive_handle->src_fd, -1, jump_size);
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
|
|
||||||
extern void seek_by_jump(const archive_handle_t *archive_handle, const unsigned int amount)
|
void seek_by_jump(const archive_handle_t *archive_handle, const unsigned int amount)
|
||||||
{
|
{
|
||||||
if (lseek(archive_handle->src_fd, (off_t) amount, SEEK_CUR) == (off_t) -1) {
|
if (lseek(archive_handle->src_fd, (off_t) amount, SEEK_CUR) == (off_t) -1) {
|
||||||
#ifdef CONFIG_FEATURE_UNARCHIVE_TAPE
|
#ifdef CONFIG_FEATURE_UNARCHIVE_TAPE
|
||||||
|
|
|
@ -19,7 +19,7 @@
|
||||||
#include "unarchive.h"
|
#include "unarchive.h"
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern void unpack_ar_archive(archive_handle_t *ar_archive)
|
void unpack_ar_archive(archive_handle_t *ar_archive)
|
||||||
{
|
{
|
||||||
char magic[7];
|
char magic[7];
|
||||||
|
|
||||||
|
|
|
@ -66,7 +66,7 @@ static void skip_header(int rpm_fd)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* No getopt required */
|
/* No getopt required */
|
||||||
extern int rpm2cpio_main(int argc, char **argv)
|
int rpm2cpio_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct rpm_lead lead;
|
struct rpm_lead lead;
|
||||||
int rpm_fd;
|
int rpm_fd;
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
#define GUNZIP_TO_STDOUT 1
|
#define GUNZIP_TO_STDOUT 1
|
||||||
#define GUNZIP_FORCE 2
|
#define GUNZIP_FORCE 2
|
||||||
|
|
||||||
extern int uncompress_main(int argc, char **argv)
|
int uncompress_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int status = EXIT_SUCCESS;
|
int status = EXIT_SUCCESS;
|
||||||
unsigned long flags;
|
unsigned long flags;
|
||||||
|
|
|
@ -125,7 +125,7 @@ static void unzip_extract(zip_header_t *zip_header, int src_fd, int dst_fd)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int unzip_main(int argc, char **argv)
|
int unzip_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
zip_header_t zip_header;
|
zip_header_t zip_header;
|
||||||
enum {v_silent, v_normal, v_list} verbosity = v_normal;
|
enum {v_silent, v_normal, v_list} verbosity = v_normal;
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
|
|
||||||
extern int clear_main(int argc, char **argv)
|
int clear_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
return printf("\033[H\033[J") != 6;
|
return printf("\033[H\033[J") != 6;
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,7 +39,7 @@ struct psf_header {
|
||||||
|
|
||||||
static void loadnewfont(int fd);
|
static void loadnewfont(int fd);
|
||||||
|
|
||||||
extern int loadfont_main(int argc, char **argv)
|
int loadfont_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int fd;
|
int fd;
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int reset_main(int argc, char **argv)
|
int reset_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
if (isatty(1)) {
|
if (isatty(1)) {
|
||||||
/* See 'man 4 console_codes' for details:
|
/* See 'man 4 console_codes' for details:
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int basename_main(int argc, char **argv)
|
int basename_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
size_t m, n;
|
size_t m, n;
|
||||||
char *s;
|
char *s;
|
||||||
|
|
|
@ -40,7 +40,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int cat_main(int argc, char **argv)
|
int cat_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
FILE *f;
|
FILE *f;
|
||||||
int retval = EXIT_SUCCESS;
|
int retval = EXIT_SUCCESS;
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
#include "libcoreutils/coreutils.h"
|
#include "libcoreutils/coreutils.h"
|
||||||
|
|
||||||
extern int cp_main(int argc, char **argv)
|
int cp_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct stat source_stat;
|
struct stat source_stat;
|
||||||
struct stat dest_stat;
|
struct stat dest_stat;
|
||||||
|
|
|
@ -289,7 +289,7 @@ static void cut_file(FILE *file)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
extern int cut_main(int argc, char **argv)
|
int cut_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
unsigned long opt;
|
unsigned long opt;
|
||||||
char *sopt, *sdopt;
|
char *sopt, *sdopt;
|
||||||
|
|
|
@ -46,7 +46,7 @@ static long kscale(long b, long bs)
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern int df_main(int argc, char **argv)
|
int df_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
long blocks_used;
|
long blocks_used;
|
||||||
long blocks_percent_used;
|
long blocks_percent_used;
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int dirname_main(int argc, char **argv)
|
int dirname_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
if (argc != 2) {
|
if (argc != 2) {
|
||||||
bb_show_usage();
|
bb_show_usage();
|
||||||
|
|
|
@ -22,7 +22,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int echo_main(int argc, char** argv)
|
int echo_main(int argc, char** argv)
|
||||||
{
|
{
|
||||||
(void)bb_echo(argc, argv);
|
(void)bb_echo(argc, argv);
|
||||||
bb_fflush_stdout_and_exit(EXIT_SUCCESS);
|
bb_fflush_stdout_and_exit(EXIT_SUCCESS);
|
||||||
|
|
|
@ -57,7 +57,7 @@ static const struct option env_long_options[] = {
|
||||||
{ 0, 0, 0, 0 }
|
{ 0, 0, 0, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
extern int env_main(int argc, char** argv)
|
int env_main(int argc, char** argv)
|
||||||
{
|
{
|
||||||
static char *cleanenv[1] = { NULL };
|
static char *cleanenv[1] = { NULL };
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int false_main(int ATTRIBUTE_UNUSED argc, char ATTRIBUTE_UNUSED **argv)
|
int false_main(int ATTRIBUTE_UNUSED argc, char ATTRIBUTE_UNUSED **argv)
|
||||||
{
|
{
|
||||||
return EXIT_FAILURE;
|
return EXIT_FAILURE;
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,7 +44,7 @@ static int adjust_column(int column, char c)
|
||||||
return column;
|
return column;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int fold_main(int argc, char **argv)
|
int fold_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
char *w_opt;
|
char *w_opt;
|
||||||
int width = 80;
|
int width = 80;
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int hostid_main(int argc, char ATTRIBUTE_UNUSED **argv)
|
int hostid_main(int argc, char ATTRIBUTE_UNUSED **argv)
|
||||||
{
|
{
|
||||||
if (argc > 1) {
|
if (argc > 1) {
|
||||||
bb_show_usage();
|
bb_show_usage();
|
||||||
|
|
|
@ -53,7 +53,7 @@ static short printf_full(unsigned int id, const char *arg, const char prefix)
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int id_main(int argc, char **argv)
|
int id_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct passwd *p;
|
struct passwd *p;
|
||||||
uid_t uid;
|
uid_t uid;
|
||||||
|
|
|
@ -49,7 +49,7 @@ static const struct option install_long_options[] = {
|
||||||
{ 0, 0, 0, 0 }
|
{ 0, 0, 0, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
extern int install_main(int argc, char **argv)
|
int install_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
mode_t mode;
|
mode_t mode;
|
||||||
uid_t uid;
|
uid_t uid;
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int length_main(int argc, char **argv)
|
int length_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
if ((argc != 2) || (**(++argv) == '-')) {
|
if ((argc != 2) || (**(++argv) == '-')) {
|
||||||
bb_show_usage();
|
bb_show_usage();
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "coreutils.h"
|
#include "coreutils.h"
|
||||||
|
|
||||||
extern int cp_mv_stat2(const char *fn, struct stat *fn_stat, stat_func sf)
|
int cp_mv_stat2(const char *fn, struct stat *fn_stat, stat_func sf)
|
||||||
{
|
{
|
||||||
if (sf(fn, fn_stat) < 0) {
|
if (sf(fn, fn_stat) < 0) {
|
||||||
if (errno != ENOENT) {
|
if (errno != ENOENT) {
|
||||||
|
@ -39,7 +39,7 @@ extern int cp_mv_stat2(const char *fn, struct stat *fn_stat, stat_func sf)
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int cp_mv_stat(const char *fn, struct stat *fn_stat)
|
int cp_mv_stat(const char *fn, struct stat *fn_stat)
|
||||||
{
|
{
|
||||||
return cp_mv_stat2(fn, fn_stat, stat);
|
return cp_mv_stat2(fn, fn_stat, stat);
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
#include "coreutils.h"
|
#include "coreutils.h"
|
||||||
|
|
||||||
extern mode_t getopt_mk_fifo_nod(int argc, char **argv)
|
mode_t getopt_mk_fifo_nod(int argc, char **argv)
|
||||||
{
|
{
|
||||||
mode_t mode = 0666;
|
mode_t mode = 0666;
|
||||||
char *smode = NULL;
|
char *smode = NULL;
|
||||||
|
|
|
@ -36,7 +36,7 @@
|
||||||
#define LN_BACKUP 8
|
#define LN_BACKUP 8
|
||||||
#define LN_SUFFIX 16
|
#define LN_SUFFIX 16
|
||||||
|
|
||||||
extern int ln_main(int argc, char **argv)
|
int ln_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int status = EXIT_SUCCESS;
|
int status = EXIT_SUCCESS;
|
||||||
int flag;
|
int flag;
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int logname_main(int argc, char ATTRIBUTE_UNUSED **argv)
|
int logname_main(int argc, char ATTRIBUTE_UNUSED **argv)
|
||||||
{
|
{
|
||||||
const char *p;
|
const char *p;
|
||||||
|
|
||||||
|
|
|
@ -955,7 +955,7 @@ static const unsigned opt_flags[] = {
|
||||||
|
|
||||||
/*----------------------------------------------------------------------*/
|
/*----------------------------------------------------------------------*/
|
||||||
|
|
||||||
extern int ls_main(int argc, char **argv)
|
int ls_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct dnode **dnd;
|
struct dnode **dnd;
|
||||||
struct dnode **dnf;
|
struct dnode **dnf;
|
||||||
|
|
|
@ -40,7 +40,7 @@ static const struct option mkdir_long_options[] = {
|
||||||
{ 0, 0, 0, 0 }
|
{ 0, 0, 0, 0 }
|
||||||
};
|
};
|
||||||
|
|
||||||
extern int mkdir_main (int argc, char **argv)
|
int mkdir_main (int argc, char **argv)
|
||||||
{
|
{
|
||||||
mode_t mode = (mode_t)(-1);
|
mode_t mode = (mode_t)(-1);
|
||||||
int status = EXIT_SUCCESS;
|
int status = EXIT_SUCCESS;
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
#include "libcoreutils/coreutils.h"
|
#include "libcoreutils/coreutils.h"
|
||||||
|
|
||||||
extern int mkfifo_main(int argc, char **argv)
|
int mkfifo_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
mode_t mode;
|
mode_t mode;
|
||||||
int retval = EXIT_SUCCESS;
|
int retval = EXIT_SUCCESS;
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
static const char modes_chars[] = { 'p', 'c', 'u', 'b', 0, 1, 1, 2 };
|
static const char modes_chars[] = { 'p', 'c', 'u', 'b', 0, 1, 1, 2 };
|
||||||
static const mode_t modes_cubp[] = { S_IFIFO, S_IFCHR, S_IFBLK };
|
static const mode_t modes_cubp[] = { S_IFIFO, S_IFCHR, S_IFBLK };
|
||||||
|
|
||||||
extern int mknod_main(int argc, char **argv)
|
int mknod_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
mode_t mode;
|
mode_t mode;
|
||||||
dev_t dev;
|
dev_t dev;
|
||||||
|
|
|
@ -46,7 +46,7 @@ static const struct option mv_long_options[] = {
|
||||||
|
|
||||||
static const char fmt[] = "cannot overwrite %sdirectory with %sdirectory";
|
static const char fmt[] = "cannot overwrite %sdirectory with %sdirectory";
|
||||||
|
|
||||||
extern int mv_main(int argc, char **argv)
|
int mv_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct stat dest_stat;
|
struct stat dest_stat;
|
||||||
const char *last;
|
const char *last;
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int pwd_main(int argc, char **argv)
|
int pwd_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
char *buf;
|
char *buf;
|
||||||
|
|
||||||
|
|
|
@ -32,7 +32,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int rm_main(int argc, char **argv)
|
int rm_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int status = 0;
|
int status = 0;
|
||||||
int flags = 0;
|
int flags = 0;
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <libgen.h>
|
#include <libgen.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int rmdir_main(int argc, char **argv)
|
int rmdir_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int status = EXIT_SUCCESS;
|
int status = EXIT_SUCCESS;
|
||||||
int flags;
|
int flags;
|
||||||
|
|
|
@ -11,7 +11,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int seq_main(int argc, char **argv)
|
int seq_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
double last, first, increment, i;
|
double last, first, increment, i;
|
||||||
|
|
||||||
|
|
|
@ -46,7 +46,7 @@ static const struct suffix_mult sleep_suffixes[] = {
|
||||||
};
|
};
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern int sleep_main(int argc, char **argv)
|
int sleep_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
unsigned int duration;
|
unsigned int duration;
|
||||||
|
|
||||||
|
|
|
@ -467,9 +467,9 @@ static const struct suffix_mult stty_suffixes[] = {
|
||||||
};
|
};
|
||||||
|
|
||||||
#ifndef TEST
|
#ifndef TEST
|
||||||
extern int stty_main(int argc, char **argv)
|
int stty_main(int argc, char **argv)
|
||||||
#else
|
#else
|
||||||
extern int main(int argc, char **argv)
|
int main(int argc, char **argv)
|
||||||
#endif
|
#endif
|
||||||
{
|
{
|
||||||
struct termios mode;
|
struct termios mode;
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int sync_main(int argc, char **argv)
|
int sync_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
bb_warn_ignoring_args(argc - 1);
|
bb_warn_ignoring_args(argc - 1);
|
||||||
|
|
||||||
|
|
|
@ -183,7 +183,7 @@ static int test_eaccess(char *path, int mode);
|
||||||
static int is_a_group_member(gid_t gid);
|
static int is_a_group_member(gid_t gid);
|
||||||
static void initialize_group_array(void);
|
static void initialize_group_array(void);
|
||||||
|
|
||||||
extern int test_main(int argc, char **argv)
|
int test_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int res;
|
int res;
|
||||||
|
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int touch_main(int argc, char **argv)
|
int touch_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int fd;
|
int fd;
|
||||||
int flags;
|
int flags;
|
||||||
|
|
|
@ -202,7 +202,7 @@ static int complement(unsigned char *buffer, int buffer_len)
|
||||||
return ix;
|
return ix;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int tr_main(int argc, char **argv)
|
int tr_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
register unsigned char *ptr;
|
register unsigned char *ptr;
|
||||||
int output_length=0, input_length;
|
int output_length=0, input_length;
|
||||||
|
|
|
@ -26,7 +26,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int true_main(int argc, char **argv)
|
int true_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
return EXIT_SUCCESS;
|
return EXIT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int tty_main(int argc, char **argv)
|
int tty_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
const char *s;
|
const char *s;
|
||||||
int silent; /* Note: No longer relevant in SUSv3. */
|
int silent; /* Note: No longer relevant in SUSv3. */
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int usleep_main(int argc, char **argv)
|
int usleep_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
if (argc != 2) {
|
if (argc != 2) {
|
||||||
bb_show_usage();
|
bb_show_usage();
|
||||||
|
|
|
@ -138,7 +138,7 @@ static int read_base64(FILE *src_stream, FILE *dst_stream)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int uudecode_main(int argc, char **argv)
|
int uudecode_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int (*decode_fn_ptr) (FILE * src, FILE * dst);
|
int (*decode_fn_ptr) (FILE * src, FILE * dst);
|
||||||
FILE *src_stream;
|
FILE *src_stream;
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
#include <sys/wait.h>
|
#include <sys/wait.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int watch_main(int argc, char **argv)
|
int watch_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
const int header_len = 40;
|
const int header_len = 40;
|
||||||
time_t t;
|
time_t t;
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
#include <time.h>
|
#include <time.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int who_main(int argc, char **argv)
|
int who_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct utmp *ut;
|
struct utmp *ut;
|
||||||
struct stat st;
|
struct stat st;
|
||||||
|
|
|
@ -27,7 +27,7 @@
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int whoami_main(int argc, char **argv)
|
int whoami_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
if (argc > 1)
|
if (argc > 1)
|
||||||
bb_show_usage();
|
bb_show_usage();
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int yes_main(int argc, char **argv)
|
int yes_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
static const char fmt_str[] = " %s";
|
static const char fmt_str[] = " %s";
|
||||||
const char *fmt;
|
const char *fmt;
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int mktemp_main(int argc, char **argv)
|
int mktemp_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
unsigned long flags = bb_getopt_ulflags(argc, argv, "dq");
|
unsigned long flags = bb_getopt_ulflags(argc, argv, "dq");
|
||||||
|
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
/* Read a block of data from stdin, write it to stdout.
|
/* Read a block of data from stdin, write it to stdout.
|
||||||
* Activity is indicated by a '.' to stderr
|
* Activity is indicated by a '.' to stderr
|
||||||
*/
|
*/
|
||||||
extern int pipe_progress_main(int argc, char **argv)
|
int pipe_progress_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
RESERVE_CONFIG_BUFFER(buf, PIPE_PROGRESS_SIZE);
|
RESERVE_CONFIG_BUFFER(buf, PIPE_PROGRESS_SIZE);
|
||||||
time_t t = time(NULL);
|
time_t t = time(NULL);
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int which_main(int argc, char **argv)
|
int which_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int status = EXIT_SUCCESS;
|
int status = EXIT_SUCCESS;
|
||||||
size_t i, count;
|
size_t i, count;
|
||||||
|
|
|
@ -52,7 +52,7 @@ void blkid_free_dev(blkid_dev dev)
|
||||||
/*
|
/*
|
||||||
* Given a blkid device, return its name
|
* Given a blkid device, return its name
|
||||||
*/
|
*/
|
||||||
extern const char *blkid_dev_devname(blkid_dev dev)
|
const char *blkid_dev_devname(blkid_dev dev)
|
||||||
{
|
{
|
||||||
return dev->bid_name;
|
return dev->bid_name;
|
||||||
}
|
}
|
||||||
|
@ -80,7 +80,7 @@ struct blkid_struct_dev_iterate {
|
||||||
struct list_head *p;
|
struct list_head *p;
|
||||||
};
|
};
|
||||||
|
|
||||||
extern blkid_dev_iterate blkid_dev_iterate_begin(blkid_cache cache)
|
blkid_dev_iterate blkid_dev_iterate_begin(blkid_cache cache)
|
||||||
{
|
{
|
||||||
blkid_dev_iterate iter;
|
blkid_dev_iterate iter;
|
||||||
|
|
||||||
|
@ -106,7 +106,7 @@ extern int blkid_dev_next(blkid_dev_iterate iter,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern void blkid_dev_iterate_end(blkid_dev_iterate iter)
|
void blkid_dev_iterate_end(blkid_dev_iterate iter)
|
||||||
{
|
{
|
||||||
if (!iter || iter->magic != DEV_ITERATE_MAGIC)
|
if (!iter || iter->magic != DEV_ITERATE_MAGIC)
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -236,7 +236,7 @@ struct blkid_struct_tag_iterate {
|
||||||
struct list_head *p;
|
struct list_head *p;
|
||||||
};
|
};
|
||||||
|
|
||||||
extern blkid_tag_iterate blkid_tag_iterate_begin(blkid_dev dev)
|
blkid_tag_iterate blkid_tag_iterate_begin(blkid_dev dev)
|
||||||
{
|
{
|
||||||
blkid_tag_iterate iter;
|
blkid_tag_iterate iter;
|
||||||
|
|
||||||
|
@ -267,7 +267,7 @@ extern int blkid_tag_next(blkid_tag_iterate iter,
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern void blkid_tag_iterate_end(blkid_tag_iterate iter)
|
void blkid_tag_iterate_end(blkid_tag_iterate iter)
|
||||||
{
|
{
|
||||||
if (!iter || iter->magic != TAG_ITERATE_MAGIC)
|
if (!iter || iter->magic != TAG_ITERATE_MAGIC)
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -14897,7 +14897,7 @@ static float calc_percent(const struct percent_tbl *tbl, int pass, int curr,
|
||||||
+ tbl->table[pass-1]);
|
+ tbl->table[pass-1]);
|
||||||
}
|
}
|
||||||
|
|
||||||
extern void e2fsck_clear_progbar(e2fsck_t ctx)
|
void e2fsck_clear_progbar(e2fsck_t ctx)
|
||||||
{
|
{
|
||||||
if (!(ctx->flags & E2F_FLAG_PROG_BAR))
|
if (!(ctx->flags & E2F_FLAG_PROG_BAR))
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -2612,7 +2612,7 @@ static rstream *next_input_file(void)
|
||||||
return &rsm;
|
return &rsm;
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int awk_main(int argc, char **argv)
|
int awk_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
char *s, *s1;
|
char *s, *s1;
|
||||||
int i, j, c, flen;
|
int i, j, c, flen;
|
||||||
|
|
|
@ -88,7 +88,7 @@ static int file_doesnt_exist(const char *filename)
|
||||||
return(stat(filename, &statbuf));
|
return(stat(filename, &statbuf));
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int patch_main(int argc, char **argv)
|
int patch_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int patch_level = -1;
|
int patch_level = -1;
|
||||||
char *patch_line;
|
char *patch_line;
|
||||||
|
|
|
@ -1108,7 +1108,7 @@ static void add_cmd_block(char *cmdstr)
|
||||||
free(temp);
|
free(temp);
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int sed_main(int argc, char **argv)
|
int sed_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int status = EXIT_SUCCESS, opt, getpat = 1;
|
int status = EXIT_SUCCESS, opt, getpat = 1;
|
||||||
|
|
||||||
|
|
|
@ -332,7 +332,7 @@ static void write1(const char *out)
|
||||||
fputs(out, stdout);
|
fputs(out, stdout);
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int vi_main(int argc, char **argv)
|
int vi_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
int c;
|
int c;
|
||||||
RESERVE_CONFIG_BUFFER(STATUS_BUFFER, STATUS_BUFFER_LEN);
|
RESERVE_CONFIG_BUFFER(STATUS_BUFFER, STATUS_BUFFER_LEN);
|
||||||
|
|
|
@ -280,7 +280,7 @@ static void load_regexes_from_file(llist_t *fopt)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
extern int grep_main(int argc, char **argv)
|
int grep_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
FILE *file;
|
FILE *file;
|
||||||
int matched;
|
int matched;
|
||||||
|
|
|
@ -1007,7 +1007,7 @@ static void reload_signal(int sig ATTRIBUTE_UNUSED)
|
||||||
}
|
}
|
||||||
#endif /* CONFIG_FEATURE_USE_INITTAB */
|
#endif /* CONFIG_FEATURE_USE_INITTAB */
|
||||||
|
|
||||||
extern int init_main(int argc, char **argv)
|
int init_main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
struct init_action *a;
|
struct init_action *a;
|
||||||
pid_t wpid;
|
pid_t wpid;
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
|
|
||||||
#ifndef CONFIG_INIT
|
#ifndef CONFIG_INIT
|
||||||
const char * const bb_shutdown_format = "\r%s\n";
|
const char * const bb_shutdown_format = "\r%s\n";
|
||||||
extern int bb_shutdown_system(unsigned long magic)
|
int bb_shutdown_system(unsigned long magic)
|
||||||
{
|
{
|
||||||
int pri = LOG_KERN|LOG_NOTICE|LOG_FACMASK;
|
int pri = LOG_KERN|LOG_NOTICE|LOG_FACMASK;
|
||||||
const char *message;
|
const char *message;
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#define S_IWGRP_OR_S_IWOTH (S_IWGRP | S_IWOTH)
|
#define S_IWGRP_OR_S_IWOTH (S_IWGRP | S_IWOTH)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern int mesg_main(int argc, char *argv[])
|
int mesg_main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
struct stat sb;
|
struct stat sb;
|
||||||
char *tty;
|
char *tty;
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include "busybox.h"
|
#include "busybox.h"
|
||||||
|
|
||||||
extern int bb_echo(int ATTRIBUTE_UNUSED argc, char **argv)
|
int bb_echo(int ATTRIBUTE_UNUSED argc, char **argv)
|
||||||
{
|
{
|
||||||
#ifndef CONFIG_FEATURE_FANCY_ECHO
|
#ifndef CONFIG_FEATURE_FANCY_ECHO
|
||||||
#define eflag '\\'
|
#define eflag '\\'
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern char *concat_path_file(const char *path, const char *filename)
|
char *concat_path_file(const char *path, const char *filename)
|
||||||
{
|
{
|
||||||
char *lc;
|
char *lc;
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern char *concat_subpath_file(const char *path, const char *f)
|
char *concat_subpath_file(const char *path, const char *f)
|
||||||
{
|
{
|
||||||
if(f && *f == '.' && (!f[1] || (f[1] == '.' && !f[2])))
|
if(f && *f == '.' && (!f[1] || (f[1] == '.' && !f[2])))
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
|
@ -62,7 +62,7 @@ out:
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
extern int bb_copyfd_size(int fd1, int fd2, const off_t size)
|
int bb_copyfd_size(int fd1, int fd2, const off_t size)
|
||||||
{
|
{
|
||||||
if (size) {
|
if (size) {
|
||||||
return(bb_full_fd_action(fd1, fd2, size));
|
return(bb_full_fd_action(fd1, fd2, size));
|
||||||
|
@ -70,7 +70,7 @@ extern int bb_copyfd_size(int fd1, int fd2, const off_t size)
|
||||||
return(0);
|
return(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
extern int bb_copyfd_eof(int fd1, int fd2)
|
int bb_copyfd_eof(int fd1, int fd2)
|
||||||
{
|
{
|
||||||
return(bb_full_fd_action(fd1, fd2, 0));
|
return(bb_full_fd_action(fd1, fd2, 0));
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
|
|
||||||
|
|
||||||
/* try to open up the specified device */
|
/* try to open up the specified device */
|
||||||
extern int device_open(const char *device, int mode)
|
int device_open(const char *device, int mode)
|
||||||
{
|
{
|
||||||
int m, f, fd = -1;
|
int m, f, fd = -1;
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "libbb.h"
|
#include "libbb.h"
|
||||||
|
|
||||||
extern void bb_error_msg(const char *s, ...)
|
void bb_error_msg(const char *s, ...)
|
||||||
{
|
{
|
||||||
va_list p;
|
va_list p;
|
||||||
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user