[epiphany] ephy-session: do not store "ephy-about" URIs



commit 15a693dd485ebdf6098387b4729174fab2055c99
Author: Xan Lopez <xan igalia com>
Date:   Thu Dec 15 00:17:49 2011 +0100

    ephy-session: do not store "ephy-about" URIs
    
    Store them as "about:" instead, which is the proper kind for loading.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=666206

 src/ephy-session.c |    7 +++++++
 1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/ephy-session.c b/src/ephy-session.c
index 6567614..39ac29f 100644
--- a/src/ephy-session.c
+++ b/src/ephy-session.c
@@ -35,6 +35,7 @@
 #include "ephy-history-window.h"
 #include "ephy-notebook.h"
 #include "ephy-prefs.h"
+#include "ephy-request-about.h"
 #include "ephy-settings.h"
 #include "ephy-shell.h"
 #include "ephy-stock-icons.h"
@@ -1116,6 +1117,12 @@ write_tab (xmlTextWriterPtr writer,
 	if (ret < 0) return ret;
 
 	address = ephy_web_view_get_address (ephy_embed_get_web_view (embed));
+	/* Do not store ephy-about: URIs, they are not valid for
+	 * loading. */
+	if (g_str_has_prefix (address, EPHY_ABOUT_SCHEME))
+	{
+		address = g_strconcat ("about", address + EPHY_ABOUT_SCHEME_LEN, NULL);
+	}
 	ret = xmlTextWriterWriteAttribute (writer, (xmlChar *) "url",
 					   (const xmlChar *) address);
 	if (ret < 0) return ret;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]