From 487129e4efe7062444f89c3870b85a11c21f26f9 Mon Sep 17 00:00:00 2001 From: Patrick Storz Date: Fri, 3 May 2019 20:14:16 +0200 Subject: Fix opening of files on Windows (and possibly elsewhere) What we pass as "uri" is not an URI, it usually seems to be a file path, so we were lucky it "accidentally" used to work before. Replace Gio::File::create_for_uri with Gio::File::create_for_commandline_arg which should handle both URIs and absolute paths reliably. --- src/extension/internal/svg.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/extension/internal/svg.cpp b/src/extension/internal/svg.cpp index 2e21ef272..e473f0df4 100644 --- a/src/extension/internal/svg.cpp +++ b/src/extension/internal/svg.cpp @@ -704,7 +704,7 @@ SPDocument * Svg::open (Inkscape::Extension::Input *mod, const gchar *uri) { // This is only used at the end... but it should go here once uri stuff is fixed. - auto file = Gio::File::create_for_uri(uri); + auto file = Gio::File::create_for_commandline_arg(uri); const auto path = file->get_path(); // Fixing this means fixing a whole string of things. -- cgit v1.2.3