summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@edwardthomson.com>2014-12-01 10:43:11 -0500
committerEdward Thomson <ethomson@edwardthomson.com>2014-12-01 10:43:11 -0500
commit169497d1e7c238d2925577d1af3dc03e9a507cd3 (patch)
tree6267ae94cce7179f6af943b1f8ea23d9cb54b1ea
parentfea15f7c74226cf0bbecd595ed7a78e1ce760204 (diff)
parent93aef71e90c8dd00eab1274cfec90d4b0a5cb7ba (diff)
downloadlibgit2-169497d1e7c238d2925577d1af3dc03e9a507cd3.tar.gz
Merge pull request #2734 from jeffhostetler/jeffhostetler/git_mkfile
fix cl_git_mkfile() to test for -1 rather than 0 for errors from p_creat...
-rw-r--r--tests/clar_libgit2.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/clar_libgit2.c b/tests/clar_libgit2.c
index faeee031a..9640b9265 100644
--- a/tests/clar_libgit2.c
+++ b/tests/clar_libgit2.c
@@ -18,7 +18,7 @@ void cl_git_mkfile(const char *filename, const char *content)
int fd;
fd = p_creat(filename, 0666);
- cl_assert(fd != 0);
+ cl_assert(fd != -1);
if (content) {
cl_must_pass(p_write(fd, content, strlen(content)));