Thomas-Tsai / partclone

Partclone provides utilities to backup a partition smartly and it is designed for higher compatibility of the file system by using existing library.
GNU General Public License v2.0
306 stars 104 forks source link

partclone return 0 in case of error #241

Closed dtronche closed 8 months ago

dtronche commented 8 months ago

When partclone exits in error, it should return a non zero status so that it can be detected. However currently exit(0) is performed

After an error, our /var/log partition was full. We tried a partclone restore which stopped after the error message open logfile parclone.log error, however our script did not detect it as the command returned 0 despite being in error.

dtronche commented 8 months ago

There are more exit 0 than this one. I think a global check should be done

Thomas-Tsai commented 8 months ago

Thanks for this bug report. I can reproduce this issue and we should find more exit 0.