From 76be3b9aead3f8a5cc915a516ed78d051a804b0a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Pawe=C5=82=20Forysiuk?= Date: Sun, 25 Mar 2012 17:47:51 +0200 Subject: [PATCH] Check stricly for relative path in midori_prepare_uri Fixes: https://bugs.launchpad.net/midori/+bug/963899 --- midori/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/midori/main.c b/midori/main.c index d6f5f4ee..65fc2059 100644 --- a/midori/main.c +++ b/midori/main.c @@ -1515,7 +1515,8 @@ midori_prepare_uri (const gchar *uri) if (g_str_has_prefix(uri, "javascript:")) return NULL; - else if (g_file_test (uri, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR)) + else if (g_file_test (uri, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR) + && !g_path_is_absolute (uri)) { gchar* current_dir = g_get_current_dir (); uri_ready = g_strconcat ("file://", current_dir, -- 2.39.5