Commit 35cdd261 by Scott J. Goldman

Fix unsigned/signed comparison on Windows in commitstagedfile.c

parent b47e0a71
......@@ -83,8 +83,16 @@ void test_object_commit_commitstagedfile__generate_predictable_object_ids(void)
struct stat st;
cl_must_pass(p_lstat("treebuilder/test.txt", &st));
cl_assert(entry->file_size == st.st_size);
#ifndef _WIN32
/*
* Windows doesn't populate these fields, and the signage is
* wrong in the Windows version of the struct, so lets avoid
* the "comparing signed and unsigned" compilation warning in
* that case.
*/
cl_assert(entry->uid == st.st_uid);
cl_assert(entry->gid == st.st_gid);
#endif
}
/*
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment