diff options
Diffstat (limited to 'include/serd/uri.h')
-rw-r--r-- | include/serd/uri.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/include/serd/uri.h b/include/serd/uri.h index 7a63f183..c978782f 100644 --- a/include/serd/uri.h +++ b/include/serd/uri.h @@ -5,6 +5,7 @@ #define SERD_URI_H #include "serd/attributes.h" +#include "serd/memory.h" #include "serd/stream.h" #include "serd/string_view.h" #include "zix/attributes.h" @@ -55,12 +56,15 @@ static const SerdURIView SERD_URI_NULL = The returned path and `*hostname` must be freed with serd_free(). + @param allocator Allocator for the returned string. @param uri A file URI. @param hostname If non-NULL, set to the hostname, if present. - @return A newly-allocated filesystem path. + + @return A newly allocated path string that must be freed with serd_free(). */ SERD_API char* ZIX_ALLOCATED -serd_parse_file_uri(const char* ZIX_NONNULL uri, +serd_parse_file_uri(SerdAllocator* ZIX_NULLABLE allocator, + const char* ZIX_NONNULL uri, char* ZIX_NONNULL* ZIX_NULLABLE hostname); /// Return true iff `string` starts with a valid URI scheme |