We need to unlink the full paths in the tmpdirs, not just the base path.
2003-08-27 Jeffrey Stedfast <fejj@ximian.com> * e-mktemp.c (e_mktemp_cleanup): We need to unlink the full paths in the tmpdirs, not just the base path. svn path=/trunk/; revision=22391
This commit is contained in:

committed by
Jeffrey Stedfast

parent
7dea6c9dc2
commit
167ff0651a
@ -1,3 +1,8 @@
|
||||
2003-08-27 Jeffrey Stedfast <fejj@ximian.com>
|
||||
|
||||
* e-mktemp.c (e_mktemp_cleanup): We need to unlink the full paths
|
||||
in the tmpdirs, not just the base path.
|
||||
|
||||
2003-08-20 Suresh Chandrasekharan <suresh.chandrasekharan@sun.com>
|
||||
|
||||
* e-time-utils.c (parse_with_strptime): Fixes #43558 Appointment
|
||||
|
@ -131,12 +131,14 @@ e_mktemp_cleanup (void)
|
||||
dir = opendir (node->data);
|
||||
if (dir) {
|
||||
while ((dent = readdir (dir)) != NULL) {
|
||||
/* yea...so if we contain
|
||||
subdirectories this won't work, but
|
||||
it shouldn't so we won't
|
||||
bother caring... */
|
||||
if (strcmp (dent->d_name, ".") && strcmp (dent->d_name, ".."))
|
||||
unlink (dent->d_name);
|
||||
char *full_path;
|
||||
|
||||
if (!strcmp (dent->d_name, ".") || !strcmp (dent->d_name, ".."))
|
||||
continue;
|
||||
|
||||
full_path = g_strdup_printf ("%s/%s", node->data, dent->d_name);
|
||||
unlink (full_path);
|
||||
g_free (full_path);
|
||||
}
|
||||
closedir (dir);
|
||||
}
|
||||
|
Reference in New Issue
Block a user