summaryrefslogtreecommitdiffstats
path: root/scripts
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2013-09-26 14:53:55 +0200
committerSascha Hauer <s.hauer@pengutronix.de>2013-09-30 07:45:31 +0200
commitce8f489122e8390360e87c84888aacfc87743a83 (patch)
treefd5e0f42e939612d925984fe47ccc193cf392274 /scripts
parentf7c132fa4c271eeea800ec9228a81b6fb5bcc0c6 (diff)
downloadbarebox-ce8f489122e8390360e87c84888aacfc87743a83.tar.gz
barebox-ce8f489122e8390360e87c84888aacfc87743a83.tar.xz
scripts/bareboxenv: Make locally used functions static
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'scripts')
-rw-r--r--scripts/bareboxenv.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/scripts/bareboxenv.c b/scripts/bareboxenv.c
index 6d6d55b1db..f372685ae7 100644
--- a/scripts/bareboxenv.c
+++ b/scripts/bareboxenv.c
@@ -35,7 +35,7 @@
#define debug(...)
-void *xmalloc(size_t size)
+static void *xmalloc(size_t size)
{
void *p = NULL;
@@ -47,7 +47,7 @@ void *xmalloc(size_t size)
return p;
}
-void *xzalloc(size_t size)
+static void *xzalloc(size_t size)
{
void *p = xmalloc(size);
memset(p, 0, size);
@@ -57,7 +57,7 @@ void *xzalloc(size_t size)
/* Find out if the last character of a string matches the one given.
* Don't underrun the buffer if the string length is 0.
*/
-char* last_char_is(const char *s, int c)
+static char *last_char_is(const char *s, int c)
{
if (s && *s) {
size_t sz = strlen(s) - 1;
@@ -85,7 +85,7 @@ int recursive_action(const char *fileName, unsigned flags,
/* concatenate path and file name to new allocation buffer,
* not adding '/' if path name already has '/'
*/
-char *concat_path_file(const char *path, const char *filename)
+static char *concat_path_file(const char *path, const char *filename)
{
char *lc, *str;
@@ -107,7 +107,7 @@ char *concat_path_file(const char *path, const char *filename)
* and skipping "." and ".." directory entries
*/
-char *concat_subpath_file(const char *path, const char *f)
+static char *concat_subpath_file(const char *path, const char *f)
{
if (f && DOT_OR_DOTDOT(f))
return NULL;
@@ -120,7 +120,7 @@ char *concat_subpath_file(const char *path, const char *f)
#include "../lib/make_directory.c"
#include "../common/environment.c"
-void usage(char *prgname)
+static void usage(char *prgname)
{
printf( "Usage : %s [OPTION] DIRECTORY FILE\n"
"Load a barebox environment sector into a directory or\n"