fix random log output

the char array returned by git_oid_fmt isn't null terminated and then
passed to a format specifier with %s. Output is thus the SHA + gargabe until a \0 is found.
Fix it by increasing the array by 1 and using git_oid_tostr which adds a \0.