Fix a system args error and simplify the code.