summaryrefslogtreecommitdiff
path: root/src/dd.c
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>1997-12-25 17:04:15 +0000
committerJim Meyering <jim@meyering.net>1997-12-25 17:04:15 +0000
commitf10648f6c76d02eee019b0a53ea6121101b9d690 (patch)
tree01b3d02ec2df9e452002a1251810cae6c0e29af1 /src/dd.c
parentd9f1fd86d901b0e2084fc0c1504c378d36848d8f (diff)
downloadcoreutils-f10648f6c76d02eee019b0a53ea6121101b9d690.tar.xz
(skip): Compare lseek return value with -1 to allow it
to be negative as signed value.
Diffstat (limited to 'src/dd.c')
-rw-r--r--src/dd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dd.c b/src/dd.c
index 66a9b1180..f71502e62 100644
--- a/src/dd.c
+++ b/src/dd.c
@@ -431,7 +431,7 @@ skip (int fdesc, char *file, uintmax_t records, size_t blocksize,
operation, fall back on using read. */
o = records * blocksize;
if (o / blocksize != records
- || lseek (fdesc, o, SEEK_SET) < 0)
+ || lseek (fdesc, o, SEEK_SET) == -1)
{
while (records-- > 0)
{