diff options
author | Patrick McDermott <pj@pehjota.net> | 2017-11-15 12:22:08 (EST) |
---|---|---|
committer | Patrick McDermott <pj@pehjota.net> | 2017-11-15 12:22:08 (EST) |
commit | a9b9d87d78f67f3d1629196c5c3b8fbad44e41e0 (patch) | |
tree | 35b6c45f77370370dee44c46779eb02667c77332 | |
parent | 7d920dc01179acf77ddb507ecfea4a32ee42c18c (diff) | |
download | marquee-a9b9d87d78f67f3d1629196c5c3b8fbad44e41e0.zip marquee-a9b9d87d78f67f3d1629196c5c3b8fbad44e41e0.tar.gz marquee-a9b9d87d78f67f3d1629196c5c3b8fbad44e41e0.tar.bz2 |
mq_web_view_load_uri(): Don't save rewritten URI as display URI
-rw-r--r-- | src/web-view.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/web-view.c b/src/web-view.c index 6cb2cb7..3c24999 100644 --- a/src/web-view.c +++ b/src/web-view.c @@ -376,6 +376,7 @@ mq_web_view_get_uri(MqWebView *web_view) void mq_web_view_load_uri(MqWebView *web_view, const gchar *uri) { + gchar *rw_uri; mq_web_view_scheme_set_methods(web_view, &web_view->scheme, &web_view->scheme_methods, uri); @@ -388,11 +389,12 @@ mq_web_view_load_uri(MqWebView *web_view, const gchar *uri) if (web_view->uri) { g_free(web_view->uri); } + web_view->uri = g_strdup(uri); - web_view->uri = web_view->scheme_methods->rewrite_uri( + rw_uri = web_view->scheme_methods->rewrite_uri( web_view, &web_view->scheme, uri); - webkit_web_view_load_uri(WEBKIT_WEB_VIEW(web_view), - web_view->uri); + webkit_web_view_load_uri(WEBKIT_WEB_VIEW(web_view), rw_uri); + g_free(rw_uri); g_object_notify_by_pspec(G_OBJECT(web_view), obj_properties[PROP_DISPLAY_URI]); |