slackbuilds_ponce/system/pdksh/patches/041_Debian-tilde-expansion.patch
2010-05-13 01:01:03 +02:00

15 lines
592 B
Diff

* Don't do tilde expansion after `=' sign in non-assignments.
Patch stolen from the posh package (closes: #187839).
Index: pdksh-5.2.14/eval.c
===================================================================
--- pdksh-5.2.14.orig/eval.c 2008-04-15 20:49:47.000000000 +0200
+++ pdksh-5.2.14/eval.c 2008-04-15 20:52:19.000000000 +0200
@@ -627,7 +627,7 @@
#endif /* BRACE_EXPAND */
case '=':
/* Note first unquoted = for ~ */
- if (!(f & DOTEMP_) && !saw_eq) {
+ if (!(f & DOTEMP_) && !saw_eq && (f & DOASNTILDE)) {
saw_eq = 1;
tilde_ok = 1;
}