diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/node.c | 5 | ||||
-rw-r--r-- | src/serdi.c | 2 |
2 files changed, 3 insertions, 4 deletions
@@ -178,8 +178,7 @@ is_dir_sep(const char c) SerdNode serd_node_new_file_uri(const uint8_t* const path, const uint8_t* const hostname, - SerdURI* const out, - const bool escape) + SerdURI* const out) { const size_t path_len = strlen((const char*)path); const size_t hostname_len = hostname ? strlen((const char*)hostname) : 0; @@ -206,7 +205,7 @@ serd_node_new_file_uri(const uint8_t* const path, for (size_t i = 0; i < path_len; ++i) { if (path[i] == '%') { serd_chunk_sink("%%", 2, &chunk); - } else if (!escape || is_uri_path_char(path[i])) { + } else if (is_uri_path_char(path[i])) { serd_chunk_sink(path + i, 1, &chunk); #ifdef _WIN32 } else if (path[i] == '\\') { diff --git a/src/serdi.c b/src/serdi.c index 2bea9e3a..6ab55b20 100644 --- a/src/serdi.c +++ b/src/serdi.c @@ -323,7 +323,7 @@ main(int argc, char** argv) base = serd_node_new_uri_from_string((const uint8_t*)argv[a], NULL, &base_uri); } else if (from_file && in_fd != stdin) { // Use input file URI - base = serd_node_new_file_uri(input, NULL, &base_uri, true); + base = serd_node_new_file_uri(input, NULL, &base_uri); } FILE* const out_fd = stdout; |