From: Christian Grothoff Date: Sat, 14 Jan 2012 23:18:23 +0000 (+0000) Subject: -LRN: use blocking writes for scanner X-Git-Tag: initial-import-from-subversion-38251~15304 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=70ebf5bc2f2f8b0980d5a00a92fa3ed987b2c1a4;p=oweals%2Fgnunet.git -LRN: use blocking writes for scanner --- diff --git a/src/fs/fs_dirmetascan.c b/src/fs/fs_dirmetascan.c index ce76b0387..6af186347 100644 --- a/src/fs/fs_dirmetascan.c +++ b/src/fs/fs_dirmetascan.c @@ -355,7 +355,7 @@ write_progress (struct AddDirContext *adc, const char *filename, wr = 1; while ((wr > 0 || errno == EAGAIN) && total_write < sizeof (reason)) { - wr = GNUNET_DISK_file_write (adc->progress_write, + wr = GNUNET_DISK_file_write_blocking (adc->progress_write, &((char *)&reason)[total_write], sizeof (reason) - total_write); if (wr > 0) total_write += wr; @@ -370,7 +370,7 @@ write_progress (struct AddDirContext *adc, const char *filename, wr = 1; while ((wr > 0 || errno == EAGAIN) && total_write < sizeof (size_t)) { - wr = GNUNET_DISK_file_write (adc->progress_write, + wr = GNUNET_DISK_file_write_blocking (adc->progress_write, &((char *)&filename_len)[total_write], sizeof (size_t) - total_write); if (wr > 0) total_write += wr; @@ -383,7 +383,7 @@ write_progress (struct AddDirContext *adc, const char *filename, wr = 1; while ((wr > 0 || errno == EAGAIN) && total_write < filename_len) { - wr = GNUNET_DISK_file_write (adc->progress_write, + wr = GNUNET_DISK_file_write_blocking (adc->progress_write, &((char *)filename)[total_write], filename_len - total_write); if (wr > 0) total_write += wr; @@ -394,7 +394,7 @@ write_progress (struct AddDirContext *adc, const char *filename, wr = 1; while ((wr > 0 || errno == EAGAIN) && total_write < sizeof (char)) { - wr = GNUNET_DISK_file_write (adc->progress_write, + wr = GNUNET_DISK_file_write_blocking (adc->progress_write, &((char *)&is_directory)[total_write], sizeof (char) - total_write); if (wr > 0) total_write += wr;