Date: Wed, 21 Sep 2011 12:46:52 GMT From: Henning Petersen <henning.petersen@t-online.de> To: freebsd-gnats-submit@FreeBSD.org Subject: misc/160866: Swapped arguments in fifo_misc.c Message-ID: <201109211246.p8LCkq3G003230@red.freebsd.org> Resent-Message-ID: <201109211250.p8LCo5sP098180@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 160866 >Category: misc >Synopsis: Swapped arguments in fifo_misc.c >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Wed Sep 21 12:50:05 UTC 2011 >Closed-Date: >Last-Modified: >Originator: Henning Petersen >Release: FreeBSD-current >Organization: >Environment: >Description: Swapped arguments in fifo_misc.c . >How-To-Repeat: >Fix: diff -u -r1.6 fifo_misc.c --- tools/regression/fifo/fifo_misc/fifo_misc.c 31 Dec 2009 20:29:58 -0000 1.6 +++ tools/regression/fifo/fifo_misc/fifo_misc.c 21 Sep 2011 08:50:14 -0000 @@ -115,7 +115,7 @@ exit(-1); } - if (lseek(reader_fd, SEEK_CUR, 1) >= 0) { + if (lseek(reader_fd, 1, SEEK_CUR) >= 0) { warnx("%s: lseek succeeded instead of returning ESPIPE", __func__); cleanfifo("testfifo", reader_fd, writer_fd); Patch attached with submission follows: diff -u -r1.6 fifo_misc.c --- tools/regression/fifo/fifo_misc/fifo_misc.c 31 Dec 2009 20:29:58 -0000 1.6 +++ tools/regression/fifo/fifo_misc/fifo_misc.c 21 Sep 2011 08:50:14 -0000 @@ -115,7 +115,7 @@ exit(-1); } - if (lseek(reader_fd, SEEK_CUR, 1) >= 0) { + if (lseek(reader_fd, 1, SEEK_CUR) >= 0) { warnx("%s: lseek succeeded instead of returning ESPIPE", __func__); cleanfifo("testfifo", reader_fd, writer_fd); >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201109211246.p8LCkq3G003230>