backup-manager: syntax error when env-variable content long
Bug #435132 reported by
schnittchen
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
backup-manager (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: backup-manager
Cron regularly sends me an email containing
/etc/cron.
expr: syntax error
/usr/share/
It looks like this doesn't break things, but I won't bet.
Apparently the reason is the usage of "env" for parsing the environment (see next post).
Upstream has the same code at the location and so should be affected as well.
Changed in backup-manager (Ubuntu): | |
status: | New → Invalid |
To post a comment you must log in.
Upon invocation from cron, backup-manager has some HAL_... environment variables containing much data.
From /usr/share/ backup- manager/ sanitize. sh, around line 97:
function replace_ deprecated_ booleans( )
{
for line in $(env)
value= $(echo "$line" | awk -F '=' '{print $2}')
do
key=$(echo "$line" | awk -F '=' '{print $1}')
#...parse, warn and modify...
done
Now set some environment variable inside bash to some very long value and check the export of "env": The value is not quoted, but broken in several lines. This breaks the above construct.
Better would be to use "export -p" or to just loop through known BM_... variables.