Age | Commit message (Collapse) | Author | Files | Lines | |
---|---|---|---|---|---|
2008-03-05 | Add compat/snprintf.c for systems that return bogus | Michal Rokos | 1 | -0/+40 | |
Some systems (namely HPUX and Windows) return -1 when maxsize in snprintf() and in vsnprintf() is reached. So replace snprintf() and vsnprintf() functions with our own ones that return correct value upon overflow. [jc: verified that review comments by J6t have been incorporated, and tightened the check to verify the resulting buffer contents, suggested by Wayne Davison] Signed-off-by: Michal Rokos <michal.rokos@nextsoft.cz> Signed-off-by: Junio C Hamano <gitster@pobox.com> |