suppress warnings about easch <applet>_main() having

no preceding prototype
This commit is contained in:
Denis Vlasenko
2007-02-03 17:28:39 +00:00
parent c7ba8b9d6c
commit 06af216528
245 changed files with 268 additions and 25 deletions

View File

@@ -15,6 +15,7 @@ enum {
VT_WAITACTIVE = 0x5607 /* wait for vt active */
};
int chvt_main(int argc, char **argv);
int chvt_main(int argc, char **argv)
{
int fd, num;

View File

@@ -15,6 +15,7 @@
#include "busybox.h"
int clear_main(int argc, char **argv);
int clear_main(int argc, char **argv)
{
return printf("\033[H\033[J") != 6;

View File

@@ -15,6 +15,7 @@
/* From <linux/vt.h> */
enum { VT_DISALLOCATE = 0x5608 }; /* free memory associated to vt */
int deallocvt_main(int argc, char *argv[]);
int deallocvt_main(int argc, char *argv[])
{
/* num = 0 deallocate all unused consoles */

View File

@@ -22,18 +22,19 @@ struct kbentry {
#define NR_KEYS 128
#define MAX_NR_KEYMAPS 256
int dumpkmap_main(int argc, char **argv);
int dumpkmap_main(int argc, char **argv)
{
struct kbentry ke;
int i, j, fd;
char flags[MAX_NR_KEYMAPS], magic[] = "bkeymap";
char flags[MAX_NR_KEYMAPS];
if (argc >= 2 && *argv[1] == '-')
if (argc >= 2 && argv[1][0] == '-')
bb_show_usage();
fd = xopen(CURRENT_VC, O_RDWR);
write(1, magic, 7);
write(1, "bkeymap", 7);
/* Here we want to set everything to 0 except for indexes:
* [0-2] [4-6] [8-10] [12] */

View File

@@ -30,6 +30,7 @@ struct psf_header {
static void loadnewfont(int fd);
int loadfont_main(int argc, char **argv);
int loadfont_main(int argc, char **argv)
{
int fd;

View File

@@ -25,6 +25,7 @@ struct kbentry {
#define NR_KEYS 128
#define MAX_NR_KEYMAPS 256
int loadkmap_main(int argc, char **argv);
int loadkmap_main(int argc, char **argv)
{
struct kbentry ke;

View File

@@ -12,6 +12,7 @@
#include "busybox.h"
int openvt_main(int argc, char **argv);
int openvt_main(int argc, char **argv)
{
int fd;

View File

@@ -15,6 +15,7 @@
#include <unistd.h>
#include "busybox.h"
int reset_main(int argc, char **argv);
int reset_main(int argc, char **argv)
{
if (isatty(1)) {

View File

@@ -9,6 +9,7 @@
/* no options, no getopt */
#include "busybox.h"
int resize_main(int argc, char **argv);
int resize_main(int argc, char **argv)
{
struct termios old, new;

View File

@@ -18,6 +18,7 @@ static const struct option setconsole_long_options[] = {
#define OPT_SETCONS_RESET 1
int setconsole_main(int argc, char **argv);
int setconsole_main(int argc, char **argv)
{
unsigned long flags;

View File

@@ -9,9 +9,6 @@
* Licensed under GPLv2 or later, see file LICENSE in this tarball for details.
*/
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
#include <sys/ioctl.h>
#include "busybox.h"
@@ -24,8 +21,8 @@ enum {
KDSETKEYCODE = 0x4B4D /* write kernel keycode table entry */
};
extern int
setkeycodes_main(int argc, char** argv)
int setkeycodes_main(int argc, char** argv);
int setkeycodes_main(int argc, char** argv)
{
int fd, sc;
struct kbkeycode a;