[epiphany] ephy-shell.c: check that the network request is not NULL before unrefing it.



commit f4ad93a86c8087df1824531fee88fb36e2c7fc26
Author: Xan Lopez <xan gnome org>
Date:   Tue Jun 2 19:12:12 2009 +0300

    ephy-shell.c: check that the network request is not NULL before unrefing it.
    
    It won't be created with, for example, about:blank.
---
 src/ephy-shell.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/src/ephy-shell.c b/src/ephy-shell.c
index 0c013b8..6a6926e 100644
--- a/src/ephy-shell.c
+++ b/src/ephy-shell.c
@@ -577,7 +577,8 @@ ephy_shell_new_tab (EphyShell *shell,
 					 previous_embed, request, flags,
 					 EPHY_EMBED_CHROME_ALL, FALSE, 0);
 
-	g_object_unref (request);
+	if (request)
+		g_object_unref (request);
 
 	return embed;
 }



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