diff options
author | P. J. McDermott <pjm@nac.net> | 2012-11-16 21:35:17 (EST) |
---|---|---|
committer | P. J. McDermott <pjm@nac.net> | 2012-11-16 21:35:17 (EST) |
commit | ca617f3a0b1c5b0516128e143c0352a204ccadea (patch) | |
tree | 1b2d4eb823b0224fc91c631f41de916e0eb412e1 | |
parent | 1e6530a93ac01d073461bd8512f72a56676ca71d (diff) |
ob_set_substvar(): Escape single quotes in value.
-rw-r--r-- | lib/control.sh | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/control.sh b/lib/control.sh index 746863e..d480c22 100644 --- a/lib/control.sh +++ b/lib/control.sh @@ -177,6 +177,9 @@ ob_set_substvar() }; ')" + # Escape single quotes in value. + _obssv_value="$(printf '%s\n' "${_obssv_value}" | sed "s/'/'\\\\''/g")" + eval "_OB_SUBSTVAR_${_obssv_name}='${_obssv_value}'" _ob_return 125 |