From 52b6f1cf491fbe2e8f3d42195c19cd970c04aae3 Mon Sep 17 00:00:00 2001 From: "rjc%netscape.com" Date: Thu, 29 Jun 2000 22:47:24 +0000 Subject: [PATCH] Fix bug # 43906: non-existant file URLs can cause template failure for bookmarks. R=waterson --- rdf/datasource/src/nsFileSystemDataSource.cpp | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/rdf/datasource/src/nsFileSystemDataSource.cpp b/rdf/datasource/src/nsFileSystemDataSource.cpp index bafa4438ac54..40c214694fad 100644 --- a/rdf/datasource/src/nsFileSystemDataSource.cpp +++ b/rdf/datasource/src/nsFileSystemDataSource.cpp @@ -808,10 +808,12 @@ FileSystemDataSource::ArcLabelsOut(nsIRDFResource *source, if (NS_FAILED(rv = fileChannel->GetFile(getter_AddRefs(aDir)))) return(rv); - PRBool isDirFlag = PR_FALSE; - rv = aDir->IsDirectory(&isDirFlag); - if (NS_FAILED(rv) && (rv != NS_ERROR_FILE_NOT_FOUND)) - return(rv); + PRBool isDirFlag = PR_FALSE; + + // ignore any errors from IsDirectory() + // so that non-existant file URLs don't confuse the template builder + nsresult temprv; + temprv = aDir->IsDirectory(&isDirFlag); nsCOMPtr array; rv = NS_NewISupportsArray(getter_AddRefs(array));