Subject: Re: [PATCH] Add compat/vsnprintf.c for systems that returns -1 on maxsize reached

From: Johannes Sixt <[email-masked]>
Date: Wed, 05 Mar 2008 17:04:12 +0100

Wayne Davison schrieb:
> Then, set a define that snprintf is bogus and use a version of
> snprintf() based on this instead:
> 
> http://rsync.samba.org/ftp/unpacked/rsync/lib/snprintf.c
> 
> That defines rsync_snprintf() and rsync_vsnprintf() functions (which
> could be renamed for git). 

No.

If one *printf function is replaced, all of them must be replaced. The
reason is that, eg. on Windows we don't have %llu, but we have %I64u. So
depending on which flavor of *printf is called, we would have to supply
the one format (rsync_printf: %llu) or the other format (fprintf et al:
%I64u).

-- Hannes