From b1d30dc791348eacd44ebd6a00d0cf166a9e1cf5 Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 13 Jun 2018 17:11:13 -0400 Subject: Remove escape parameter from serd_node_new_file_uri Since characters are escaped because they are not valid characters in a URI, any use of this function without escaping is problematic at best. --- include/serd/serd.h | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'include/serd') diff --git a/include/serd/serd.h b/include/serd/serd.h index 851dce1b..69315b18 100644 --- a/include/serd/serd.h +++ b/include/serd/serd.h @@ -379,9 +379,8 @@ serd_node_new_uri_from_string(const uint8_t* SERD_NULLABLE str, /** Create a new file URI node from a file system path and optional hostname. - Backslashes in Windows paths will be converted and '%' will always be - percent encoded. If `escape` is true, all other invalid characters will be - percent encoded as well. + Backslashes in Windows paths will be converted, and other characters will be + percent encoded as necessary. If `path` is relative, `hostname` is ignored. If `out` is not NULL, it will be set to the parsed URI. @@ -389,8 +388,7 @@ serd_node_new_uri_from_string(const uint8_t* SERD_NULLABLE str, SERD_API SerdNode serd_node_new_file_uri(const uint8_t* SERD_NONNULL path, const uint8_t* SERD_NULLABLE hostname, - SerdURI* SERD_NULLABLE out, - bool escape); + SerdURI* SERD_NULLABLE out); /** Create a new node by serialising `uri` into a new string. -- cgit v1.2.1