Re: [leaf-devel] Busybox has buggy regex handling

2008-02-29 Thread Mats Erik Andersson
Hello Charles Steinkuehler, tor 2008-02-28 klockan 23:12 -0600 skrev Charles Steinkuehler: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Mats Erik Andersson wrote: > | Hi folks, > | > | this is preliminary information that Busybox does > | not possess a full command of regular expression

Re: [leaf-devel] Busybox has buggy regex handling

2008-02-29 Thread Erich Titl
Hi Mats Just out of curiosity I tested your code > on AIX > # #!/bin/sh # # lager=/tmp/tillf # # { > echo -e "abab\nbaab\nabba" | egrep '^(a?[ab]|ba){2}$' > echo -e "abab\nbaab\nabba" | egrep '^(ba|a?[ab]){2}$' > } > $lager # |

Re: [leaf-devel] Busybox has buggy regex handling

2008-02-29 Thread Mats Erik Andersson
Dear Eric, I will leave all your code for reference, and add one more for OpenBSD. The really bad news is that uClibc (Berin 1.2/3.1) is assymmetric: five hits, where I went to efforts to construct symmetric test cases. As for AIX, the answer is symmetric, but could you possible test a deeper grou

Re: [leaf-devel] Busybox has buggy regex handling

2008-02-29 Thread Erich Titl
Hi Mats Mats Erik Andersson schrieb: > Dear Eric, > > I will leave all your code for reference, and add one more > for OpenBSD. The really bad news is that uClibc (Berin 1.2/3.1) > is assymmetric: five hits, where I went to efforts to construct > symmetric test cases. As for AIX, the answer is sy

Re: [leaf-devel] Busybox has buggy regex handling

2008-02-29 Thread Mats Erik Andersson
Hello again Eric, I am beginning to doubt the portability of regular expressions altogether. A fully grouped pattern seems to be what AIX needs: echo -e "abab\nbaab\nabba" | egrep '^((a?[ab])|(ba)){2}$' echo -e "abab\nbaab\nabba" | egrep '^((ba)|(a?[ab])){2}$' If this does not work, AIX stays ho

Re: [leaf-devel] Busybox has buggy regex handling

2008-02-29 Thread Lynn Avants
LEAF/LRP shells have always (and apparently) still rather limited in use. During which periods I was writing any shell code I found that you should NEVER ASSUME it will work on the target system. There are issues due to what shell 'sh' is linked to at a minimum. This is not confined to LEAF/LRP sy