core: convert git-access.c to C++

Had to make sha.h compatible with C++.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-02-27 23:22:49 +01:00 committed by Michael Keller
parent b0438ad1dd
commit 924b23ed56
5 changed files with 70 additions and 80 deletions

View file

@ -8,7 +8,7 @@ static char *strndup (const char *s, size_t n)
size_t len = strlen(s);
if (n < len)
len = n;
if ((cpy = malloc(len + 1)) !=
if ((cpy = (char *)malloc(len + 1)) !=
NULL) {
cpy[len] =
'\0';