git: f0c8d2cd622a - main - shar: Make sure a sed failure in the generated archive results in failure
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Tue, 18 Feb 2025 17:17:20 UTC
The branch main has been updated by cy:
URL: https://cgit.FreeBSD.org/src/commit/?id=f0c8d2cd622a47e06c08620a10e13ad7519e9102
commit f0c8d2cd622a47e06c08620a10e13ad7519e9102
Author: Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2025-01-02 03:44:18 +0000
Commit: Cy Schubert <cy@FreeBSD.org>
CommitDate: 2025-02-18 17:16:48 +0000
shar: Make sure a sed failure in the generated archive results in failure
Obtained from: NetBSD hg commit 365369:21b92f0055b4
MFC after: 1 week
---
usr.bin/shar/shar.sh | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/usr.bin/shar/shar.sh b/usr.bin/shar/shar.sh
index 3a7bf2db41e5..52c31b419fc4 100644
--- a/usr.bin/shar/shar.sh
+++ b/usr.bin/shar/shar.sh
@@ -68,7 +68,7 @@ do
md5sum=`echo -n "$i" | md5`
echo "echo x - '$i'"
echo "sed 's/^X//' >'$i' << '$md5sum'"
- sed 's/^/X/' "$i" || exit
+ sed 's/^/X/' "$i" || exit 1
echo "$md5sum"
fi
done