Regression to ignore retcodes on crontab calls

This commit is contained in:
Beorn Facchini 2018-04-03 10:03:45 +10:00 committed by rallytime
parent 422441505d
commit f8beab71dd
No known key found for this signature in database
GPG key ID: E8F1A4B90D0DEA19

View file

@ -282,12 +282,14 @@ def raw_cron(user):
# Preserve line endings
lines = sdecode(__salt__['cmd.run_stdout'](cmd,
runas=user,
ignore_retcode=True,
rstrip=False,
python_shell=False)).splitlines(True)
else:
cmd = 'crontab -u {0} -l'.format(user)
# Preserve line endings
lines = sdecode(__salt__['cmd.run_stdout'](cmd,
ignore_retcode=True,
rstrip=False,
python_shell=False)).splitlines(True)