Improves the -G, --gui output.

This commit is contained in:
Andrea Mazzoleni 2013-09-30 22:24:30 +02:00
parent 750e21ec87
commit d35beda689
10 changed files with 165 additions and 29 deletions

10
sync.c
View file

@ -442,6 +442,16 @@ static int state_sync_process(struct snapraid_state* state, struct snapraid_pari
printf("Everything OK\n");
}
if (state->opt.gui) {
fprintf(stdlog, "summary:error_readwrite:%u\n", error);
fprintf(stdlog, "summary:error_data:%u\n", silent_error);
if (error + silent_error == 0)
fprintf(stdlog, "summary:exit:ok\n");
else
fprintf(stdlog, "summary:exit:error\n");
fflush(stdlog);
}
bail:
for(j=0;j<diskmax;++j) {
ret = handle_close(&handle[j]);