From 049c9c6b186b156894dd3d63463e6ce46c60231d Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Sun, 21 Sep 2014 01:49:59 +0200 Subject: [PATCH] Make file module work on python 2.4, fix #9080 Python 2.4 do not support "except ... as ..." construct, so revert back to the older syntax. --- library/files/file | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/files/file b/library/files/file index e25278fded7..2f26a3bc312 100644 --- a/library/files/file +++ b/library/files/file @@ -339,7 +339,7 @@ def main(): module.fail_json(msg='Cannot touch other than files and directories') try: module.set_fs_attributes_if_different(file_args, True) - except SystemExit as e: + except SystemExit, e: if e.code: # We take this to mean that fail_json() was called from # somewhere in basic.py