delorie.com/archives/browse.cgi   search  
Mail Archives: opendos/1997/11/30/15:56:53

To: opendos AT delorie DOT com, opendos-support AT delorie DOT com
References: <s481c489 DOT 079 AT calderauk DOT com>
Message-Id: <ABfzSWq8DK@belous.munic.msk.su>
From: "Arkady V.Belousov" <ark AT belous DOT munic DOT msk DOT su>
Date: Sun, 30 Nov 1997 23:41:13 +0300 (MSK)
Organization: Locus
Reply-To: ark AT mos DOT ru
Subject: Re: OpenDOS 7.02b2 bugs
Lines: 41
MIME-Version: 1.0

X-Comment-To: Matthias Paul

Hi!

30-ξΟΡ-97 19:54 MPaul AT calderauk DOT com (Matthias Paul) wrote to opendos AT delorie DOT com, opendos-support AT delorie DOT com:
 > On 97-11-30, Arkady V.Belousov replied:

 > >>  0 - usual run, even if target file not found, or files have different size
 > >> OS/2 COMP returns the following errorlevel:
 > >> 5 - files were not equal
 > >> I have not tested the MS-DOS  errorlevels.
 > >> Of course, OpenDOS should at least report errorlevel 5 if file are not equal...
 > >    Where you see errorlevel 5 above? Look:
 > >[batchjob deleted]
 > >     Try "cmp file1 file2", where files differs by size or by contents and
 > >watch result (superfluous questions and always "compare ok."). :(
 > Yes, that s what I meant, too.

     No. You assume compatability between "comp" from OS/2 and from OpenDOS,
although this contrary docs and practice.

 > I was just reporting the status quo. ;-)
 > The returned errorlevels are not very helpful for batchjob programming,
 > but this could be because of MS-DOS compatiblity (again, I have NOT
 > verified the errorlevels with MS-DOS).

     No. I mean not troubles with manipulating "errorlevel" (this is not
troubles _for me_). I point: "comp" from OD (also as from MS-/PC-DOS) quite
not report presence of differences through errorlevel, so _you_ (also) can't
check this in batches.

     If I right understand, you not understand me - may be because you
forget: "if errorlevel <n>" check return code for equal _or greater_ than
<n>, so

        if errorlevel 1 echo greater 0
        if errorlevel 5 echo greater 4

both call echo when errorlevel are 5.

[...skip for example of innovation (%errorlevel%) in OD's command.com...]


- Raw text -


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