diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2017-06-22 13:37:40 +0200 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2017-06-28 10:27:31 +0200 |
commit | ca517e8b320c7a31c3a147fb1212ddb33cabd919 (patch) | |
tree | a26d535836a82ea241dc0389b061176ddfcd8329 /nand-utils/nandtest.c | |
parent | 3029b659e89caa79b6860c3bbe8cbc18b53af678 (diff) |
Eliminate warnings about missing prototypes
This patch eliminates warnings generated by the -Wmissing-prototypes
option. With this flag set, we are now forced to have prototypes for
all global, exported functions, that have to be made visible to the
definitions and we are forced to mark all local functions as static.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'nand-utils/nandtest.c')
-rw-r--r-- | nand-utils/nandtest.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/nand-utils/nandtest.c b/nand-utils/nandtest.c index 9e39446..d5c7369 100644 --- a/nand-utils/nandtest.c +++ b/nand-utils/nandtest.c @@ -17,7 +17,7 @@ #include "mtd/mtd-user.h" #include "common.h" -void usage(int status) +static void usage(int status) { fprintf(status ? stderr : stdout, "usage: %s [OPTIONS] <device>\n\n" @@ -40,7 +40,8 @@ int fd; int markbad=0; int seed; -int read_and_compare(loff_t ofs, unsigned char *data, unsigned char *rbuf) +static int read_and_compare(loff_t ofs, unsigned char *data, + unsigned char *rbuf) { ssize_t len; int i; @@ -89,7 +90,8 @@ int read_and_compare(loff_t ofs, unsigned char *data, unsigned char *rbuf) return 0; } -int erase_and_write(loff_t ofs, unsigned char *data, unsigned char *rbuf, int nr_reads) +static int erase_and_write(loff_t ofs, unsigned char *data, unsigned char *rbuf, + int nr_reads) { struct erase_info_user er; ssize_t len; |