]> pilppa.com Git - uci.git/commitdiff
move get_filename as well
authorFelix Fietkau <nbd@openwrt.org>
Sat, 26 Jan 2008 11:17:33 +0000 (12:17 +0100)
committerFelix Fietkau <nbd@openwrt.org>
Sat, 26 Jan 2008 11:17:33 +0000 (12:17 +0100)
file.c
list.c

diff --git a/file.c b/file.c
index 6f437153ba11349c11bd6fcd6e313c763c8a76a0..7e5a8acc741fa98872385c1dd94da786bbc1c841 100644 (file)
--- a/file.c
+++ b/file.c
@@ -564,6 +564,16 @@ int uci_load(struct uci_context *ctx, const char *name, struct uci_package **pac
        return uci_import(ctx, file, name, package);
 }
 
+static inline char *get_filename(char *path)
+{
+       char *p;
+
+       p = strrchr(path, '/');
+       p++;
+       if (!*p)
+               return NULL;
+       return p;
+}
 
 char **uci_list_configs(struct uci_context *ctx)
 {
diff --git a/list.c b/list.c
index 2142b716de3e1a8fd07df39e90c393c42b94f97d..066a9fd789008474e25b7aecd476857018756318 100644 (file)
--- a/list.c
+++ b/list.c
@@ -215,14 +215,4 @@ found:
        return 0;
 }
 
-static inline char *get_filename(char *path)
-{
-       char *p;
-
-       p = strrchr(path, '/');
-       p++;
-       if (!*p)
-               return NULL;
-       return p;
-}