Commit fa3daa8259df6c09a7e075b0b959eabc791f92f9

lhchavez 2020-10-13T08:02:59

Define `git___load` when building with `-DTHREADSAFE=OFF` This should allow folks that build in non-thread-safe environments to still be able to build the library. Fixes: #5663

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
diff --git a/src/thread-utils.h b/src/thread-utils.h
index ecb4909..3311672 100644
--- a/src/thread-utils.h
+++ b/src/thread-utils.h
@@ -311,6 +311,11 @@ GIT_INLINE(volatile void *) git___swap(
 	return old;
 }
 
+GIT_INLINE(volatile void *) git___load(void * volatile *ptr)
+{
+	return *ptr;
+}
+
 #ifdef GIT_ARCH_64
 
 GIT_INLINE(int64_t) git_atomic64_add(git_atomic64 *a, int64_t addend)