Re: [9fans] on cp /fd/1 /fd/0

2015-05-12 Thread Daniel Bastos
On Tue, May 12, 2015 at 1:15 PM, Charles Forsyth charles.fors...@gmail.com wrote: On 12 May 2015 at 15:17, Daniel Bastos dbas...@toledo.com wrote: What is the relationship between file descriptor 1 and /fd/1? When a program runs, 1 is already open for writing. But apparently it's open only

Re: [9fans] on cp /fd/1 /fd/0

2015-05-12 Thread Charles Forsyth
On 12 May 2015 at 15:17, Daniel Bastos dbas...@toledo.com wrote: What is the relationship between file descriptor 1 and /fd/1? When a program runs, 1 is already open for writing. But apparently it's open only for writing. A read on it yields inappropriate use of fd. The same seems to happen

[9fans] on cp /fd/1 /fd/0

2015-05-12 Thread Daniel Bastos
Good morning. % cp /fd/1 /fd/0 cp: can't open /fd/1: '/fd/1' inappropriate use of fd I can't open it for reading, but I could open it for writing. Why can't I open it for reading?

Re: [9fans] on cp /fd/1 /fd/0

2015-05-12 Thread Iruatã Souza
--r d 0 glenda glenda 0 May 10 18:57 0 --rw--- d 0 glenda glenda 0 May 10 18:57 1 ---w--- d 0 glenda glenda 0 May 10 18:57 2 is that what you want to know? or the reasons why the permissions are like that? On Tue, May 12, 2015 at 8:56 AM, Daniel Bastos dbas...@toledo.com wrote:

Re: [9fans] on cp /fd/1 /fd/0

2015-05-12 Thread lucio
--r d 0 glenda glenda 0 May 10 18:57 0 --rw--- d 0 glenda glenda 0 May 10 18:57 1 ---w--- d 0 glenda glenda 0 May 10 18:57 2 is that what you want to know? or the reasons why the permissions are like that? Except that OP wants to know why reading /fd/1 isn't allowed when

Re: [9fans] on cp /fd/1 /fd/0

2015-05-12 Thread Daniel Bastos
On Tue, May 12, 2015 at 9:24 AM, Iruatã Souza iru.mu...@gmail.com wrote: --r d 0 glenda glenda 0 May 10 18:57 0 --rw--- d 0 glenda glenda 0 May 10 18:57 1 ---w--- d 0 glenda glenda 0 May 10 18:57 2 is that what you want to know? or the reasons why the permissions are like

Re: [9fans] on cp /fd/1 /fd/0

2015-05-12 Thread erik quanstrom
Except that OP wants to know why reading /fd/1 isn't allowed when the permissions allow it. I suspect something is a bit obscure, like the implementation being different from the stated permissions. i imagine that the permissions on the underlying device are wrong. cons is 600 in rio, and i