aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorXan Lopez <xan@gnome.org>2009-09-04 03:23:22 +0800
committerXan Lopez <xan@gnome.org>2009-09-04 03:23:22 +0800
commitd5db22b6842017772f10aa28d18458f36b025677 (patch)
tree31c06127d1b4013f65ffe28589b686d8f2d6b1ca /src
parentfdc216467277bb6235c9c7fc6f3ace9a3a37bc8a (diff)
downloadgsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.tar
gsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.tar.gz
gsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.tar.bz2
gsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.tar.lz
gsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.tar.xz
gsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.tar.zst
gsoc2013-epiphany-d5db22b6842017772f10aa28d18458f36b025677.zip
ephy-session.c: fix opening an empty new epiphany window from command line
By not asking ephy to do silly things.
Diffstat (limited to 'src')
-rw-r--r--src/ephy-session.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/ephy-session.c b/src/ephy-session.c
index 5774354ba..e77d12b73 100644
--- a/src/ephy-session.c
+++ b/src/ephy-session.c
@@ -648,7 +648,7 @@ session_command_open_uris (EphySession *session,
{
const char *url = uris[i];
EphyNewTabFlags page_flags;
- WebKitNetworkRequest *request;
+ WebKitNetworkRequest *request = NULL;
if (url[0] == '\0')
{
@@ -657,9 +657,9 @@ session_command_open_uris (EphySession *session,
else
{
page_flags = EPHY_NEW_TAB_OPEN_PAGE;
+ request = webkit_network_request_new (url);
}
- request = webkit_network_request_new (url);
embed = ephy_shell_new_tab_full (shell, window,
NULL /* parent tab */,
request,
@@ -667,7 +667,8 @@ session_command_open_uris (EphySession *session,
EPHY_WEB_VIEW_CHROME_ALL,
FALSE /* is popup? */,
user_time);
- g_object_unref (request);
+ if (request)
+ g_object_unref (request);
window = EPHY_WINDOW (gtk_widget_get_toplevel (GTK_WIDGET (embed)));
}