Leak in nautilus-directory-async.c
- From: Kjartan Maraas <kmaraas broadpark no>
- To: nautilus-list gnome org
- Subject: Leak in nautilus-directory-async.c
- Date: Thu, 14 Apr 2005 12:22:35 +0200
Hi.
Valgrind pointed me to leaks in this area and it seems the following
patch fixes them:
diff -u -p -r1.212 nautilus-directory-async.c
--- nautilus-directory-async.c 22 Nov 2004 15:24:35 -0000 1.212
+++ nautilus-directory-async.c 14 Apr 2005 10:21:11 -0000
@@ -1971,6 +1971,7 @@ read_dot_hidden_file (NautilusDirectory
file_info = gnome_vfs_file_info_new ();
if (!file_info) {
+ gnome_vfs_uri_unref (dot_hidden_vfs_uri);
return;
}
@@ -1978,6 +1979,7 @@ read_dot_hidden_file (NautilusDirectory
dot_hidden_vfs_uri,
file_info,
GNOME_VFS_FILE_INFO_DEFAULT) != GNOME_VFS_OK) {
+ gnome_vfs_uri_unref (dot_hidden_vfs_uri);
gnome_vfs_file_info_unref (file_info);
return;
}
@@ -1988,6 +1990,7 @@ read_dot_hidden_file (NautilusDirectory
gnome_vfs_file_info_unref (file_info);
if (!file_ok) {
+ gnome_vfs_uri_unref (dot_hidden_vfs_uri);
return;
}
Does this look correct?
Cheers
Kjartan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]