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vL36I(B
(B[EMAIL PROTECTED]
(B
(B
(B
(B
(B___
(BBug-bash mailing list
(BBug-bash@gnu.org
(Bhttp://lists.gnu.org/mailman/listinfo/bug-bash

about pipe

2005-02-21 Thread gan_xiao_jun
Hi,

while running:

myapp 2>/dev/null&

I want to change 2>&1 without stop this job.
Is there some tips to finish it?

Thanks in advance
gan




__ 
Do you Yahoo!? 
Yahoo! Mail - Helps protect you from nasty viruses. 
http://promotions.yahoo.com/new_mail


___
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash


More bash POSIX-compliance bugs

2005-02-21 Thread Eric Blake
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

While searching for more details about the requirement for `pwd -P' to set
PWD in POSIX mode, I found several other compliance bugs:

1) time is no longer allowed to be a reserved word.  For example:
$ set -o posix
$ alias !='echo hi;'
$ alias time='echi hi;'
$ ! true# ! is reserved word, not alias
$ echo $?
1
$ time true # BUG: time should be an alias, and echo hi

real0m0.000s
user0m0.000s
sys 0m0.000s
$ set +o posix
$ ! true# outside of posix mode, bash documents that
hi  # aliases take precedence over reserved words
$ echo $?
0
$ time true # BUG: again, time should be an alias

real0m0.000s
user0m0.000s
sys 0m0.000s
$

(Likewise, source is not documented as a reserved word, but since time is
a POSIX-required utiltiy while source is not, I am okay with source
remaining a reserved word.)


2) The wording of bash-3.0/POSIX is misleading on item 4.  Rather than
stating "Reserved words may not be aliased", you should state something
like "An aliased reserved word does not undergo alias expansion if it is
in the context of a reserved word".  As demonstrated in POSIX XRAT, an
aliased reserved word that is not in the context of a reserved word
undergoes alias expansion:
$ alias while=hi
$ alias foo='echo '
$ foo while
hi


3) Items 18 and 19 of bash-3.0/POSIX are wrong.  Reread the description of
cd (http://www.opengroup.org/onlinepubs/009695399/utilities/cd.html), the
interpretation on it
(http://www.opengroup.org/austin/interps/uploads/40/6230/AI-037.txt), and
pending corrections to the interpretation
(https://www.opengroup.org/sophocles/show_mail.tpl?source=L&listname=austin-group-l&id=8042).
 Item 18 is wrong because there is nothing that states that the use of
CDPATH turns on -P handling.  And item 19 is wrong because when CDPATH
without . fails to find a directory in step 5, step 6 reverts to using
$PWD (the current directory).  The following example is required to behave
the same in POSIX mode as it currently does for normal bash mode:

$ set -o posix
$ cd /tmp
$ mkdir -p a a/aa
$ ln -s a b
$ CDPATH=b cd aa
/tmp/b/aa
$ echo $PWD  # BUG: Should be /tmp/b/aa, as printed
/tmp/a/aa
$ cd -
/tmp
$ CDPATH=/tmp/a/aa cd b  # BUG: Should change to /tmp/b, and set PWD
bash: cd: b: No such file or directory


4) POSIX requires that times be a special built-in.  For example:
$ foo=bar times
0m0.140s 0m0.156s
0m2.078s 0m0.683s
$ echo foo: $foo   # BUG: should print foo: bar
foo:
$

(On a related note, I think POSIX is ambiguous on the behavior of the
following - does the setting of foo take place before or after it is unset?
$ foo=bar unset foo
$ echo $foo # Some shells echo bar, others echo nothing
)


5) POSIX requires that newgrp be provided as a regular shell built-in, as
well as a standalone utility.  POSIX states that "A common implementation
of newgrp is that the current shell uses exec to overlay itself with
newgrp, which in turn overlays itself with a new shell after changing
group. On some implementations, however, this may not occur and newgrp may
be invoked as a subprocess."  It is the action of overlaying the current
shell with newgrp which was the rationale for providing newgrp as a
regular built-in, even if you choose to implement the built-in by simply
deferring to the standalone utility rather than changing groups within
bash before starting the new shell environment.  On cygwin, where no one
has yet ported a newgrp utility, bash currently fails to be
POSIX-compliant because of the missing newgrp builtin:
$ newgrp
bash: newgrp: command not found

- --
Life is short - so eat dessert first!

Eric Blake [EMAIL PROTECTED]

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.0 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFCGejm84KuGfSFAYARAo+PAKCny1cKGdJl8GMe2Q/7OzDpuEBT4wCgwZyN
2hfpZJ3mrIAIwiGD0B6L3J4=
=2B62
-END PGP SIGNATURE-


___
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash


Problem in the reverse history search

2005-02-21 Thread luca . martini
Configuration Information [Automatically generated, do not change]:
Machine: i386
OS: linux-gnu
Compiler: i386-redhat-linux-gcc
Compilation CFLAGS:  -DPROGRAM='bash' -DCONF_HOSTTYPE='i386' 
-DCONF_OSTYPE='linux-gnu' -DCONF_MACHTYPE='i386-redhat-linux-gnu' 
-DCONF_VENDOR='redhat' -DLOCALEDIR='/usr/share/locale' -DPACKAGE='bash' -DSHELL 
-DHAVE_CONFIG_H  -I.  -I. -I./include -I./lib  -D_FILE_OFFSET_BITS=64 -O2 -g 
-pipe -m32 -march=i386 -mtune=pentium4
uname output: Linux toubkal 2.6.10-1.741_FC3smp #1 SMP Thu Jan 13 16:53:16 EST 
2005 i686 i686 i386 GNU/Linux
Machine Type: i386-redhat-linux-gnu

Bash Version: 3.0
Patch Level: 14
Release Status: release

Description:
sometimes, using the reverse search in the history (CTRL-r) and 
choosing a past command typing two letters, the command is executed, but on the 
shell the first letter matched is missing. 


Repeat-By:
$bashbug-32 --help
[CTRL+r]--
$bashbug-32 -help
GNU bashbug, version 3.0.14-release ..etc


___
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash


Re: about pipe

2005-02-21 Thread Chet Ramey
[EMAIL PROTECTED] wrote:
Hi,
while running:
myapp 2>/dev/null&
I want to change 2>&1 without stop this job.
Is there some tips to finish it?
Unless the app itself responds to a signal to do that, there
is no way to accomplish it.  At that point, it's out of the
shell's hands.
Chet
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
( ``Discere est Dolere'' -- chet )
Live...Laugh...Love
Chet Ramey, ITS, CWRU[EMAIL PROTECTED]http://tiswww.tis.cwru.edu/~chet/
___
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash


Re: about pipe

2005-02-21 Thread Stephane Chazelas
On Mon, Feb 21, 2005 at 05:19:22AM -0800, [EMAIL PROTECTED] wrote:
[...]
> while running:
> 
> myapp 2>/dev/null&
> 
> I want to change 2>&1 without stop this job.
> Is there some tips to finish it?
[...]

If you mean that you also want to discard stdout, you can try:

gdb myapp << EOF
attach $!
call dup2(2,1)
detach
EOF

or:

gdb myapp << EOF
set auto-solib-add off
attach $!
share libc\\..*
call dup2(1,2)
detach
EOF

myapp needs to be linked dynamically to the libc and even then,
hat's not guaranteed to work.

-- 
Stéphane


___
Bug-bash mailing list
Bug-bash@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-bash


[EMAIL PROTECTED]

2005-02-21 Thread hame-king
$B%O%a%-%s%0;vL36I$G$9!#(B
(B
$B%O%a%-%s%0$4MxMQD:$-M-Fq$&8f:B$$$^$9!#Ev%5%$%H$O$*5$$KF~$j(B
$BD:$$$F$*$j$^$9$G$7$g$&$+!)4|4VFb$O;H$$J|Bj$G$4MxMQD:$1$^$9!#(B
$B?o;~!"%O%a%-%s%0:G?72hA|$r%,%s%,%s7G:\Cf$J$N$G$*8+F($7L5$/!*!*(B
(B
$B$5$F!"[EMAIL PROTECTED]:]$N$4MxMQNA6b$,[EMAIL 
(BPROTECTED]<$H$J$C$F$*$j$^$9!#(B
(B[EMAIL PROTECTED]|$,5.EB$N$*?69~$_:G=*4|F|$H$J$j$^$9!#(B
(B
$B4|F|Fb$N$*?69~$_$,3NG'$G$-$J$$!&$4O"Mm$N$D$+$J$$!&[EMAIL 
(BPROTECTED];W$,$J$$!&0-[EMAIL 
(BPROTECTED]@!<>pJs!K$r85$KD4::5!4X(B(http://g-research.jp/)$B$X?H85D4::$r0MMj$$$?$7$^$9!#$=$N>pJs$r85$K:D8"2s<}6H@\2s<}$5$;[EMAIL
(B PROTECTED]/$3$H$K$J$j$^$9$N$G!"$*;YJ'$$4|F|$r:FEY$43NG'$/[EMAIL PROTECTED](B
(B
$B$*;YJ'$$!&$4MxMQNA6b3NG'$K$D$-$^$7$F$O2<5-%Z!<[EMAIL 
(BPROTECTED];2>H2<$5$$!#(B
$B!J$J$*!"[EMAIL PROTECTED]@!"$42rLshttp://1107.ch/pts/?g=_default&pn=fakereg&id=f78fd9d000981ea
(B
$B"($*?69~$_4|F|$N:G=*F|$,EZF|!&=K:WF|$H=E$J$k>l9g$O6d9TAk8}$NMb1D6HF|$N8a8e(B3$B;~$^$G$K$*?69~$_2<$5$$!#(B
(B
(B
$BEv%5%$%H$O0-5=;[EMAIL PROTECTED]"$j$^$;$s!#(B
$B!1!1!1!1!1!1!1!1!1!1!1!1!1!1!1!1(B
$B%O%a%-%s%0;vL36I(B
(B[EMAIL PROTECTED]
(B
(B
(B
(B
(B___
(BBug-bash mailing list
(BBug-bash@gnu.org
(Bhttp://lists.gnu.org/mailman/listinfo/bug-bash