df: parallel: Add a debug message when work function returns an error.

Further attempts to find out why this hangs under Koji.
This commit is contained in:
Richard W.M. Jones
2013-10-08 12:15:52 +01:00
parent 5c53b32669
commit 74d9fdf56f

View File

@@ -194,9 +194,15 @@ worker_thread (void *thread_data_vp)
guestfs_set_verbose (g, thread_data->verbose);
/* Do work. */
if (thread_data->work (g, i, fp) == -1)
if (thread_data->work (g, i, fp) == -1) {
thread_data->r = -1;
if (thread_data->verbose)
fprintf (stderr,
"parallel: thread %zu work function returned an error\n",
thread_data->thread_num);
}
fclose (fp);
guestfs_close (g);