aboutsummaryrefslogtreecommitdiffstats
path: root/embed/mozilla/FilePicker.cpp
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2004-01-10 19:19:52 +0800
committerChristian Persch <chpe@src.gnome.org>2004-01-10 19:19:52 +0800
commit137a5961bbd03f74a90927ae1a03ed5e19e5d666 (patch)
tree710be6153d725c44fa97993e3dee32aaf74ef9d6 /embed/mozilla/FilePicker.cpp
parent264834c946c5555c48b1fda985c6513c23773228 (diff)
downloadgsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.tar
gsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.tar.gz
gsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.tar.bz2
gsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.tar.lz
gsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.tar.xz
gsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.tar.zst
gsoc2013-epiphany-137a5961bbd03f74a90927ae1a03ed5e19e5d666.zip
Use NS_ENSURE_SUCCESS/NS_ENSURE_TRUE at appropriate places.
2004-01-10 Christian Persch <chpe@cvs.gnome.org> * embed/mozilla/FilePicker.cpp: * embed/mozilla/MozDownload.cpp: * embed/mozilla/MozRegisterComponents.cpp: * embed/mozilla/MozillaPrivate.cpp: Use NS_ENSURE_SUCCESS/NS_ENSURE_TRUE at appropriate places.
Diffstat (limited to 'embed/mozilla/FilePicker.cpp')
-rw-r--r--embed/mozilla/FilePicker.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/embed/mozilla/FilePicker.cpp b/embed/mozilla/FilePicker.cpp
index 4dd0340b8..71685c958 100644
--- a/embed/mozilla/FilePicker.cpp
+++ b/embed/mozilla/FilePicker.cpp
@@ -297,7 +297,8 @@ NS_IMETHODIMP GFilePicker::GetFileURL(nsIFileURL **aFileURL)
{
nsCOMPtr<nsILocalFile> file;
GetFile (getter_AddRefs(file));
-
+ NS_ENSURE_TRUE (file, NS_ERROR_FAILURE);
+
nsCOMPtr<nsIFileURL> fileURL = do_CreateInstance (NS_STANDARDURL_CONTRACTID);
fileURL->SetFile(file);
NS_IF_ADDREF(*aFileURL = fileURL);