Commit c3f182bc by Augustus Kling

Fix error reporting in case locale-gen fails on non-Ubuntu systems.

parent 1fb830fb
...@@ -70,7 +70,7 @@ def apply_change(targetState, name, encoding): ...@@ -70,7 +70,7 @@ def apply_change(targetState, name, encoding):
localeGenExitValue = call("locale-gen") localeGenExitValue = call("locale-gen")
if localeGenExitValue!=0: if localeGenExitValue!=0:
module.fail_json(msg="locale.gen failed to execute, it returned "+str(localeGenExitValue)) raise EnvironmentError(localeGenExitValue, "locale.gen failed to execute, it returned "+str(localeGenExitValue))
def apply_change_ubuntu(targetState, name, encoding): def apply_change_ubuntu(targetState, name, encoding):
"""Create or remove locale. """Create or remove locale.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment