aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/ChangeLog5
-rw-r--r--src/lib/cfuns-c.c4
2 files changed, 9 insertions, 0 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 1c630fbb..981cc7ec 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,3 +1,8 @@
+2009-07-10 Alfredo Portes <doyenatccny@gmail.com>
+
+ * lib/cfuns-c.c (writeablep): Use function LocalFree()
+ in Windows instead of free().
+
2009-07-06 Gabriel Dos Reis <gdr@cs.tamu.edu>
Fix SF/2815437
diff --git a/src/lib/cfuns-c.c b/src/lib/cfuns-c.c
index e7fa22ec..849af3c4 100644
--- a/src/lib/cfuns-c.c
+++ b/src/lib/cfuns-c.c
@@ -247,7 +247,11 @@ writeablep(char *path)
is writable. */
char* dir = oa_dirname(path);
code = stat(dir, &buf);
+#ifdef __WIN32__
+ LocalFree(dir);
+#else
free(dir);
+#endif
return (code == 0) && axiom_has_write_access(&buf) ? 2 : -1;
}