X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fuci.git;a=blobdiff_plain;f=file.c;h=7e5a8acc741fa98872385c1dd94da786bbc1c841;hp=6f437153ba11349c11bd6fcd6e313c763c8a76a0;hb=ed971c19dfb7a07abdfe9f58ba04b31aa49d306a;hpb=a16f02de27a2c486e5abc5faa7bbed5871a31228;ds=sidebyside diff --git a/file.c b/file.c index 6f43715..7e5a8ac 100644 --- 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) {