summaryrefslogtreecommitdiff
path: root/coreutils/printf.c
diff options
context:
space:
mode:
authorDenis Vlasenko2008-07-22 20:16:55 +0000
committerDenis Vlasenko2008-07-22 20:16:55 +0000
commit0f293b96dc6effa127ec63e11dd16221f1329126 (patch)
treea5b7873a5ece9bef8355da8d437cf53f952c66ca /coreutils/printf.c
parent68a192c00799fd2097bab1aec594cd27203b1ec6 (diff)
downloadbusybox-0f293b96dc6effa127ec63e11dd16221f1329126.zip
busybox-0f293b96dc6effa127ec63e11dd16221f1329126.tar.gz
fix all cases of strcpy on overlapping strings.
Diffstat (limited to 'coreutils/printf.c')
-rw-r--r--coreutils/printf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/coreutils/printf.c b/coreutils/printf.c
index 7f6235a..72acbc7 100644
--- a/coreutils/printf.c
+++ b/coreutils/printf.c
@@ -289,7 +289,7 @@ static char **print_formatted(char *f, char **argv)
/* Remove size modifiers - "%Ld" would try to printf
* long long, we pass long, and it spews garbage */
if ((*f | 0x20) == 'l' || *f == 'h' || *f == 'z') {
- strcpy(f, f + 1);
+ overlapping_strcpy(f, f + 1);
}
//FIXME: actually, the same happens with bare "%d":
//it printfs an int, but we pass long!