[gmime] Fixed for ENABLE_MBOX_MATCH
- From: Jeffrey Stedfast <fejj src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gmime] Fixed for ENABLE_MBOX_MATCH
- Date: Mon, 20 Feb 2012 22:17:26 +0000 (UTC)
commit 7e0d5ccbff6d3f879e19b1355c81f2827fd1fe95
Author: Jeffrey Stedfast <fejj gnome org>
Date: Mon Feb 20 17:16:47 2012 -0500
Fixed for ENABLE_MBOX_MATCH
tests/test-mbox.c | 16 ++++++++++++++--
1 files changed, 14 insertions(+), 2 deletions(-)
---
diff --git a/tests/test-mbox.c b/tests/test-mbox.c
index 1575be3..bef5904 100644
--- a/tests/test-mbox.c
+++ b/tests/test-mbox.c
@@ -244,7 +244,7 @@ int main (int argc, char **argv)
int fd, i;
#ifdef ENABLE_MBOX_MATCH
- if (g_mkdir ("./tmp", 0755) == -1 && errno != EEXIST)
+ if (mkdir ("./tmp", 0755) == -1 && errno != EEXIST)
return 0;
#endif
@@ -436,7 +436,19 @@ int main (int argc, char **argv)
exit:
#ifdef ENABLE_MBOX_MATCH
- g_rmdir ("./tmp");
+ if ((dir = g_dir_open ("./tmp", 0, NULL))) {
+ p = g_stpcpy (input, "./tmp");
+ *p++ = G_DIR_SEPARATOR;
+
+ while ((dent = g_dir_read_name (dir))) {
+ strcpy (p, dent);
+ unlink (input);
+ }
+
+ g_dir_close (dir);
+ }
+
+ rmdir ("./tmp");
#endif
testsuite_end ();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]