summaryrefslogtreecommitdiff
path: root/quote.h
diff options
context:
space:
mode:
authorLibravatar Jonathan Nieder <jrnieder@gmail.com>2011-03-16 00:14:22 -0500
committerLibravatar Junio C Hamano <gitster@pobox.com>2011-03-17 15:30:47 -0700
commit31d713d069f6586c3b18aa721ccd668fa994219c (patch)
treecac7d5dc6e8528cd0d422478bdd296e018830d65 /quote.h
parentPrepare draft release notes to 1.7.4.2 (diff)
downloadtgif-31d713d069f6586c3b18aa721ccd668fa994219c.tar.xz
mktag: avoid %td in format string
Since v1.7.0-rc0~34 (make "mktag" a built-in, 2010-01-22), git mktag uses the C99-style %td format to print ptrdiff_t values. It falls back to %d when NO_C99_FORMAT is set, on the assumption that pre-C99 systems probably are using 32-bit pointers. But many modern systems are 64-bit and * sometimes one wants to test the NO_C99_FORMAT fallbacks using a modern development platform; * some platforms (I'm looking at you, msvc) have not gotten with the program and are still C89-only. These ptrdiff_t values are offsets from the beginning of a buffer, so a size_t or uintmax_t would work about as well. Use the latter so we can take advantage of the PRIuMAX fallback in git-compat-util.h, even on C99-challenged systems with 64-bit pointers. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'quote.h')
0 files changed, 0 insertions, 0 deletions