mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-01 04:12:51 +00:00
Use quotes around the first_line variable so C comments and other things
that are misinterpreted by echo(1) aren't. PR: docs/8757 Submitted By: Takeshi OHASHI <ohashi@mickey.ai.kyutech.ac.jp> Sergei Laskavy <laskavy@gambit.msk.su>
This commit is contained in:
parent
c56690ef7b
commit
6faaa698e4
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=41604
@ -26,7 +26,7 @@ else
|
||||
# Plain text or HP/PCL, so just print it directly; print a form
|
||||
# at the end to eject the last page.
|
||||
#
|
||||
echo $first_line && cat && printf "\f" && exit 2
|
||||
echo "$first_line" && cat && printf "\f" && exit 2
|
||||
fi
|
||||
|
||||
exit 2
|
||||
|
@ -12,12 +12,12 @@ if [ "$first_two_chars" = "%!" ]; then
|
||||
#
|
||||
# PostScript job, print it.
|
||||
#
|
||||
echo $first_line && cat && printf "\004" && exit 0
|
||||
echo "$first_line" && cat && printf "\004" && exit 0
|
||||
exit 2
|
||||
else
|
||||
#
|
||||
# Plain text, convert it, then print it.
|
||||
#
|
||||
( echo $first_line; cat ) | /usr/local/bin/textps && printf "\004" && exit 0
|
||||
( echo "$first_line"; cat ) | /usr/local/bin/textps && printf "\004" && exit 0
|
||||
exit 2
|
||||
fi
|
||||
|
Loading…
Reference in New Issue
Block a user