diff --git a/tunasync_snapshot_gc.py b/tunasync_snapshot_gc.py index 60957f8..cdbb2eb 100644 --- a/tunasync_snapshot_gc.py +++ b/tunasync_snapshot_gc.py @@ -27,8 +27,8 @@ if __name__ == "__main__": print("GC: {}".format(abs_fname)) try: ret = sh.btrfs("subvolume", "delete", abs_fname) - except sh.ErrorReturnCode: - print("Error: {}".format(ret.stderr)) + except sh.ErrorReturnCode, e: + print("Error: {}".format(e.stderr)) else: walk(abs_fname, level+1)