replaced os.system() by subprocess.call() and fixed escaping errors