Fix truncation of SHA in error message for git_odb_read#3818
Conversation
|
Welcome @meatcoder ! That's for looking into this; Since
So I think that while this fixes the common case (when the ID is of length |
|
Thanks for looking at this and the detailed explanation @ethomson. I've updated the pull request to to also fix the cases where shorter ID strings are passed to |
|
This looks great, thanks @meatcoder ! |
Fix truncation of SHA in error message for git_odb_read

This is an attempt to fix #3753. The bug appears to only occur when the
oid_lenparameter passed togit_odb__error_notfound()is the maximum length of GIT_OID_HEXSZ. This PR fixes it by passing the actual buffer length togit_oid_tostr().