mirror of https://github.com/ansible/ansible.git
Don't send unicode instances to the selinux module
This fixes #2632. Briefly: specifying things like paths using complex args in a playbook will make the objects unicode instances. The selinux module does not accept unicode instances for its char * arguments; it wants str instances. Per mpdehaan's comment on #2632 I just went ahead and converted all paths to UTF-8. I don't know if it would be better to do something like converting to locale.getpreferredencoding(), but I factored all the conversions out into new method _to_filesystem_str, so there's only one place that needs to be changed in the future.pull/2727/head
parent
66afe13346
commit
c8f4a56cad
Loading…
Reference in New Issue