delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2005/02/28/13:29:14

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
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
Date: Mon, 28 Feb 2005 13:29:02 -0500
From: Christopher Faylor <cgf-no-personal-reply-please AT cygwin DOT com>
To: cygwin AT cygwin DOT com
Subject: Re: cygwin bughunt (snapshot)
Message-ID: <20050228182902.GK29453@trixie.casa.cgf.cx>
Reply-To: cygwin AT cygwin DOT com
References: <79F81D5F4790D344B05F489CE2AC8AB7146D63 AT dubexdc03 DOT dubex DOT net>
Mime-Version: 1.0
In-Reply-To: <79F81D5F4790D344B05F489CE2AC8AB7146D63@dubexdc03.dubex.net>
User-Agent: Mutt/1.4.1i

On Mon, Feb 28, 2005 at 06:53:50PM +0100, David Dindorp wrote:
>Bash seems to think that it's child has terminated prematurely.
>Has anyone experienced something similar?
>
>Evidence: See the order of execution in the script below,
>compare with what bash does (further below).
>
>Version: snapshot 20050226 / bash 3.0.
>
>If I'm grossly missing anything from my error reports,
>could you please point it out?  Thank you...

http://cygwin.com/problems.html

>Script:
>======================
>tar --remove-files --ignore-failed-read -cvf \
>    "$arcrfname" "$arcsourcedir"
>
>cerr=$?
>
>sleep 30
>
>if [ $cerr -ne 0 ]; then
>  echo "`date +'%Y-%m-%d %H:%M:%S'`: TAR error $cerr."
>fi
>
>if [ -f "$arcrfname" ]; then
>  echo "`date +'%Y-%m-%d %H:%M:%S'`: TAR OK."
>else
>  echo "`date +'%Y-%m-%d %H:%M:%S'`: TAR failed."
>fi
>======================

It's difficult to see how this could be an actual run of the above script.

>Log file:
>======================
>+++ tar --remove-files --ignore-failed-read -cvf \
>    /0007-02-2005-02-28-14-05-06-readyarchive_quick.tar ready-quick
                                                         ^^^^^^^^^^^
>+++ cerr=0
>+++ sleep 30
>+++ '[' 0 -ne 0 ']'
>+++ '[' -f 0007-02-2005-02-28-14-05-06-readyarchive_quick.tar ']'
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
What happened to the leading slash?

>++++ date '+%Y-%m-%d %H:%M:%S'
>tar: Removing leading `/' from member names
>/var/ready-quick/
 ^^^^^^^^^^^^^^^^^
Where did the /var come from?  It wasn't mentioned in the output above.

FWIW, when I try this, everything works as expected.  It's difficult to
see how this could be executed out of order unless your tar and/or sleep
are not standard cygwin programs.

cgf

--
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