diff options
-rw-r--r-- | coreutils/dd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/coreutils/dd.c b/coreutils/dd.c index 7247f55e0..b7979d62f 100644 --- a/coreutils/dd.c +++ b/coreutils/dd.c | |||
@@ -268,7 +268,7 @@ int dd_main(int argc, char **argv) | |||
268 | goto die_outfile; | 268 | goto die_outfile; |
269 | } | 269 | } |
270 | 270 | ||
271 | while ((flags & FLAG_COUNT) && (G.in_full + G.in_part != count)) { | 271 | while (!(flags & FLAG_COUNT) || (G.in_full + G.in_part != count)) { |
272 | if (flags & FLAG_NOERROR) /* Pre-zero the buffer if conv=noerror */ | 272 | if (flags & FLAG_NOERROR) /* Pre-zero the buffer if conv=noerror */ |
273 | memset(ibuf, 0, ibs); | 273 | memset(ibuf, 0, ibs); |
274 | n = safe_read(ifd, ibuf, ibs); | 274 | n = safe_read(ifd, ibuf, ibs); |