summaryrefslogtreecommitdiff
path: root/jffsX-utils/mkfs.jffs2.c
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2017-06-22 13:37:40 +0200
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2017-06-28 10:27:31 +0200
commitca517e8b320c7a31c3a147fb1212ddb33cabd919 (patch)
treea26d535836a82ea241dc0389b061176ddfcd8329 /jffsX-utils/mkfs.jffs2.c
parent3029b659e89caa79b6860c3bbe8cbc18b53af678 (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 'jffsX-utils/mkfs.jffs2.c')
-rw-r--r--jffsX-utils/mkfs.jffs2.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/jffsX-utils/mkfs.jffs2.c b/jffsX-utils/mkfs.jffs2.c
index 2fb7730..9aa6c39 100644
--- a/jffsX-utils/mkfs.jffs2.c
+++ b/jffsX-utils/mkfs.jffs2.c
@@ -112,7 +112,7 @@ static int squash_perms = 0;
static int fake_times = 0;
int target_endian = __BYTE_ORDER;
-uint32_t find_hardlink(struct filesystem_entry *e)
+static uint32_t find_hardlink(struct filesystem_entry *e)
{
struct filesystem_entry *f;
struct rb_node **n = &hardlinks.rb_node;
@@ -139,7 +139,7 @@ uint32_t find_hardlink(struct filesystem_entry *e)
return 0;
}
-extern char *xreadlink(const char *path)
+static char *xreadlink(const char *path)
{
static const int GROWBY = 80; /* how large we will grow strings by */
@@ -1428,7 +1428,7 @@ static const char helptext[] =
" -V, --version Display version information\n"
" -i, --incremental=FILE Parse FILE and generate appendage output for it\n\n";
-int load_next_block() {
+static int load_next_block(void) {
int ret;
ret = read(in_fd, file_buffer, erase_block_size);
@@ -1439,7 +1439,7 @@ int load_next_block() {
return ret;
}
-void process_buffer(int inp_size) {
+static void process_buffer(int inp_size) {
uint8_t *p = file_buffer;
union jffs2_node_union *node;
uint16_t type;
@@ -1542,7 +1542,7 @@ void process_buffer(int inp_size) {
}
}
-void parse_image(){
+static void parse_image(void){
int ret;
file_buffer = xmalloc(erase_block_size);