[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Change all occurences of "echo -n" to "printf" for portability (issue 59
Change all occurences of "echo -n" to "printf" for portability (issue 5903046)
Sat, 24 Mar 2012 06:00:52 +0000
File scripts/build/install-info-html.sh (right):
scripts/build/install-info-html.sh:129: printf "$name: Writing index:
This is dangerous since $name could contain print control characters.
So one should rather write
printf "%s: Writing index: %s..." "$name" "$index_file..."
File smart-autogen.sh (right):
smart-autogen.sh:16: printf $AUTOGEN_INPUT_CHECKSUM > $CHECKSUM_FILE
I'd prefer "%s" "$AUTOGEN_INPUT_CHECKSUM" here too in order to avoid
teaching sloppy use of printf, but it can't actually do harm here since
md5sum does not produce backslashes or percent characters.
File smart-configure.sh (right):
smart-configure.sh:19: printf $CONFIGURE_CHECKSUM >
See last comment.
File stepmake/bin/stepmakeise.sh (right):
stepmake/bin/stepmakeise.sh:37: printf "Checking version..."
Good enough: literal string without control or format characters is
|[Prev in Thread]
||[Next in Thread]|
- Change all occurences of "echo -n" to "printf" for portability (issue 5903046),