summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Turner <digit@android.com>2011-06-23 06:13:53 -0700
committerAndroid Git Automerger <android-git-automerger@android.com>2011-06-23 06:13:53 -0700
commitcd9f1f0b2726fbaac75b47231eb80a91841231f9 (patch)
treed367dd243c481bf169de36f327964d5191d619be
parentb489666086265eb756f11fd224137c7e3a03a707 (diff)
parentac56f5ca2f4c54ddbd37b033f9465d89542c2cbe (diff)
downloadbionic-cd9f1f0b2726fbaac75b47231eb80a91841231f9.zip
bionic-cd9f1f0b2726fbaac75b47231eb80a91841231f9.tar.gz
bionic-cd9f1f0b2726fbaac75b47231eb80a91841231f9.tar.bz2
am ac56f5ca: Merge "strftime: Use snprintf() instead of sprintf()"
* commit 'ac56f5ca2f4c54ddbd37b033f9465d89542c2cbe': strftime: Use snprintf() instead of sprintf()
-rw-r--r--libc/tzcode/strftime.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libc/tzcode/strftime.c b/libc/tzcode/strftime.c
index ab713fb..a2cc3b3 100644
--- a/libc/tzcode/strftime.c
+++ b/libc/tzcode/strftime.c
@@ -407,9 +407,9 @@ label:
tm = *t;
mkt = mktime64(&tm);
if (TYPE_SIGNED(time64_t))
- (void) sprintf(buf, "%lld",
+ (void) snprintf(buf, sizeof(buf), "%lld",
(long long) mkt);
- else (void) sprintf(buf, "%llu",
+ else (void) snprintf(buf, sizeof(buf), "%llu",
(unsigned long long) mkt);
pt = _add(buf, pt, ptlim, modifier);
}