From csardi.gabor at gmail.com  Thu May 14 15:27:27 2015
From: csardi.gabor at gmail.com (=?UTF-8?B?R8OhYm9yIENzw6FyZGk=?=)
Date: Thu, 14 May 2015 09:27:27 -0400
Subject: [Rd] Reading exit code of pipe()
In-Reply-To: <CAJXgQP3TH2xmyhBCoOow9XzxXzQdvAL0RnLCof8=zd1s1kLXQw@mail.gmail.com>
References: <CABFfbXv7OzDSt3n9HwkG3Oat0sH3t47LYQZT7ja7QBJQOY9sGw@mail.gmail.com>
	<CAJXgQP3TH2xmyhBCoOow9XzxXzQdvAL0RnLCof8=zd1s1kLXQw@mail.gmail.com>
Message-ID: <CABtg=KmZEcWA2NpVOMB+WdLyootQsKEjC89SDa7_GwcWG3YaOw@mail.gmail.com>

On Thu, May 14, 2015 at 1:27 AM, Kevin Ushey <kevinushey at gmail.com> wrote:
[...]

> So maybe `cat` just doesn't set a status code, and so there's nothing
> for R to forward back (ergo -- NULL)?
>

cat definitely sets the status. IMHO every command sets the exit status, by
definition, at least on Unix/Linux.

/tmp$ touch x
/tmp$ cat x
/tmp$ echo $?
0
/tmp$ cat y
cat: y: No such file or directory
/tmp$ echo $?
1

Gabor

[...]

	[[alternative HTML version deleted]]



[Rd] Reading exit code of pipe()
=?UTF-8?B?R8OhYm9yIENzw6FyZGk=?=