diff options
-rw-r--r-- | libstore/Makefile | 2 | ||||
-rw-r--r-- | libstore/url.c | 8 |
2 files changed, 9 insertions, 1 deletions
diff --git a/libstore/Makefile b/libstore/Makefile index 7795b97a..bfbb4937 100644 --- a/libstore/Makefile +++ b/libstore/Makefile @@ -26,7 +26,7 @@ libname = libstore SRCS = create.c derive.c make.c rdwr.c set.c device.c file.c stripe.c \ enc.c encode.c decode.c clone.c argp.c std.c kids.c zero.c flags.c \ open.c remap.c xinl.c task.c typed.c copy.c gunzip.c map.c mvol.c \ - bunzip2.c part.c nbd.c memobj.c + bunzip2.c part.c nbd.c memobj.c url.c LCLHDRS=store.h installhdrs=store.h diff --git a/libstore/url.c b/libstore/url.c index 7ed11833..967f1342 100644 --- a/libstore/url.c +++ b/libstore/url.c @@ -36,6 +36,14 @@ find_url_class (const char *name, const struct store_class *const *classes) && strncmp (name, (*cl)->name, (clname_end - name)) == 0) return *cl; +# pragma weak store_module_open_class + if (classes == 0 && store_module_open_class) + { + const struct store_class *cl; + if (store_module_open_class (name, &cl) == 0) + return cl; + } + return 0; } |