Commit 390272a3 authored by Darin Adler's avatar Darin Adler

Fix segfault when viewing a directory without a metafile.

parent 72acf48f
2000-01-20 Darin Adler <darin@eazel.com>
* libnautilus/nautilus-directory.c:
(nautilus_directory_get_file_metadata): Fix segfault that was
happening when viewing a folder without a metafile.
2000-01-19 Darin Adler <darin@eazel.com>
The list view now has a background color just like the
......
......@@ -630,6 +630,8 @@ nautilus_directory_get_file_metadata (NautilusDirectory *directory,
/* The root itself represents the directory. */
root = xmlDocGetRootElement (directory->details->metafile_tree);
if (root == NULL)
return g_strdup (default_metadata);
/* The children represent the files.
This linear search is temporary.
......
......@@ -630,6 +630,8 @@ nautilus_directory_get_file_metadata (NautilusDirectory *directory,
/* The root itself represents the directory. */
root = xmlDocGetRootElement (directory->details->metafile_tree);
if (root == NULL)
return g_strdup (default_metadata);
/* The children represent the files.
This linear search is temporary.
......
......@@ -630,6 +630,8 @@ nautilus_directory_get_file_metadata (NautilusDirectory *directory,
/* The root itself represents the directory. */
root = xmlDocGetRootElement (directory->details->metafile_tree);
if (root == NULL)
return g_strdup (default_metadata);
/* The children represent the files.
This linear search is temporary.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment