1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

Merge pull request #1807 from willthames/openlog_unicode_fix

syslog.openlog does not cope with unicode first argument
This commit is contained in:
Daniel Hokka Zakrisson 2013-01-05 08:17:03 -08:00
commit 947ec34116

View file

@ -549,7 +549,7 @@ class AnsibleModule(object):
journal.sendv(*journal_args)
else:
msg = ''
syslog.openlog('ansible-%s' % os.path.basename(__file__), 0, syslog.LOG_USER)
syslog.openlog('ansible-%s' % str(os.path.basename(__file__)), 0, syslog.LOG_USER)
for arg in log_args:
msg = msg + arg + '=' + str(log_args[arg]) + ' '
if msg: