Date: 24 Jul 2000 16:52:56 -0000 From: trost@cloud.rain.com To: FreeBSD-gnats-submit@freebsd.org Subject: bin/20143: "cmp -s" broken when reading a pipe Message-ID: <20000724165256.7413.qmail@grey.cloud.rain.com>
next in thread | raw e-mail | index | archive | help
>Number: 20143 >Category: bin >Synopsis: "cmp -s" broken when reading a pipe >Confidential: no >Severity: critical >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Jul 24 10:00:01 PDT 2000 >Closed-Date: >Last-Modified: >Originator: Bill Trost >Release: FreeBSD 4.1-RC2 i386 >Organization: Trost Computing >Environment: -- >Description: "cmp -s" will incorrectly report that files are different if one of the files is standard input. >How-To-Repeat: $ date > a $ cmp -s a a || echo different $ cat a | cmp - a || echo different $ cat a | cmp -s - a || echo different different >Fix: I've changed a script that uses "cmp -s" to just use "cmp" and redirect stdout to /dev/null. >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20000724165256.7413.qmail>