delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2008/02/17/17:19:42

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
Date: Sun, 17 Feb 2008 14:19:06 -0800
From: Lester Ingber <ingber AT ingber DOT com>
To: cygwin AT cygwin DOT com, jloup AT gzip DOT org
Subject: zdiff 1.3.12 still not correct
Message-ID: <20080217221906.GA7252@ingber.com>
MIME-Version: 1.0
User-Agent: Mutt/1.5.15 (2007-04-06)
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

On Cygwin
/bin/zdiff 1.3.12 still is not correct.  Line 107 reads
                               eval "$cmp" /dev/fd/5 -) 5<&0

whereas it probably should read something like
                               eval "$cmp" /dev/fd/5 - >&3) 5<&0

I looked at source zdiff.in in gzip-1.312 and on line 107 it has
                               eval "$cmp" /dev/fd/5 -) 5<&0

I use my own /usr/local/bin/zdiff with line 107 having
                               eval "$cmp" /dev/fd/5 - >&3) 5<&0

For example, I created zdiff_mod.in from zdiff.in the gzip-1.3.12 source:
14:05:01 @lester:~% diff zdiff.in zdiff_mod.in
107c107
<                              eval "$cmp" /dev/fd/5 -) 5<&0
---
>                              eval "$cmp" /dev/fd/5 - >$3) 5<&0
14:05:47 @lester:~% gzip zdiff.in zdiff_mod.in
14:06:10 @lester:~% /bin/zdiff zdiff.in.gz zdiff_mod.in.gz
14:06:28 @lester:~% /usr/local/bin/zdiff zdiff.in.gz zdiff_mod.in.gz
107c107
<                              eval "$cmp" /dev/fd/5 -) 5<&0
---
>                              eval "$cmp" /dev/fd/5 - >$3) 5<&0
14:06:39 @lester:~% diff zdiff.in.gz zdiff_mod.in.gz
Files zdiff.in.gz and zdiff_mod.in.gz differ

In other words, /bin/zdiff does not report any difference between
zdiff.in and zdiff_mod.in.

I would be surprised if this already has not lead to some bad results
for some users who use these utilities daily to check their codes.

Thanks for your attention to this matter

Lester


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019