diff options
author | Andy Grover <agrover@redhat.com> | 2015-04-08 11:56:57 -0700 |
---|---|---|
committer | Andy Grover <agrover@redhat.com> | 2015-04-08 11:56:57 -0700 |
commit | 70fd2ef47176239af91155e445fc106d18253afb (patch) | |
tree | fb7d5fa253b9e0da01a9818749c7f406b5532a82 | |
parent | e1808aef9638ab580a2dc1da9372fa1f10b1acc4 (diff) | |
download | rtslib-fb-70fd2ef47176239af91155e445fc106d18253afb.tar.gz |
Do not fail if there were recoverable errors on restore
There may be some changes in attributes that cause previously correct
values to return with -EINVAL. Report these via stderr but do not return
-1, because this will cause systemd to count the entire service start
as having failed.
Signed-off-by: Andy Grover <agrover@redhat.com>
-rwxr-xr-x | scripts/targetctl | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/scripts/targetctl b/scripts/targetctl index 9d02b91..3920558 100755 --- a/scripts/targetctl +++ b/scripts/targetctl @@ -50,13 +50,8 @@ def restore(from_file): print("No saved config file at %s, ok, exiting" % from_file) sys.exit(0) - if errors: - print("Restore failed, %d errors:" % len(errors), file=err) - - for error in errors: - print(error, file=err) - - sys.exit(-1) + for error in errors: + print(error, file=err) def clear(unused): RTSRoot().clear_existing(confirm=True) |