Discussion:
Which commit for a bug in 4.3.48 which is fixed in 4.4.23
Dr. Werner Fink
2018-09-21 11:11:38 UTC
Permalink
Hi,

with 4.3.48 the line

T="";echo ">${T//*/ }<"

leads to
<
but with 4.4.23 the correct result is given back
<
in the git repro I do not find any useful login entry for this

Werner
--
"Having a smoking section in a restaurant is like having
a peeing section in a swimming pool." -- Edward Burr
Eduardo A. Bustamante López
2018-09-21 16:52:29 UTC
Permalink
Post by Dr. Werner Fink
Hi,
with 4.3.48 the line
T="";echo ">${T//*/ }<"
leads to
<
but with 4.4.23 the correct result is given back
<
in the git repro I do not find any useful login entry for this
Check commit 34ec1876071b76d3654a418682e3f34ca9a72f1a:

+lib/glob/gmisc.c
+ - match_pattern_char, match_pattern_wchar: if passed an empty string,
+ return a match if the first character of the pattern is `*'
+
+subst.c
+ - pat_subst: change to allow empty strings to be replaced as long as
+ pattern matches empty string. Report and fix from isabella parakiss
+ <***@gmail.com>

In particular, this change to match_pattern:

@@ -4435,7 +4437,7 @@ match_pattern (string, pat, mtype, sp, ep)
size_t slen, plen, mslen, mplen;
#endif

- if (string == 0 || *string == 0 || pat == 0 || *pat == 0)
+ if (string == 0 || pat == 0 || *pat == 0)
return (0);
Dr. Werner Fink
2018-09-24 11:09:01 UTC
Permalink
Post by Dr. Werner Fink
Hi,
with 4.3.48 the line
T="";echo ">${T//*/ }<"
leads to
<
but with 4.4.23 the correct result is given back
<
in the git repro I do not find any useful login entry for this
Reconstructed the attached patch ... seems to work
--
"Having a smoking section in a restaurant is like having
a peeing section in a swimming pool." -- Edward Burr
Eduardo Bustamante
2018-09-24 17:50:26 UTC
Permalink
On Mon, Sep 24, 2018 at 4:09 AM Dr. Werner Fink <***@suse.de> wrote:
(...)
Post by Dr. Werner Fink
Reconstructed the attached patch ... seems to work
Out of curiosity, what problem are you trying to solve?
Chet Ramey
2018-09-24 17:52:54 UTC
Permalink
Post by Eduardo Bustamante
(...)
Post by Dr. Werner Fink
Reconstructed the attached patch ... seems to work
Out of curiosity, what problem are you trying to solve?
https://bugzilla.novell.com/show_bug.cgi?id=1107430
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU ***@case.edu http://tiswww.cwru.edu/~chet/
Dr. Werner Fink
2018-09-25 07:15:36 UTC
Permalink
Post by Chet Ramey
Post by Eduardo Bustamante
(...)
Post by Dr. Werner Fink
Reconstructed the attached patch ... seems to work
Out of curiosity, what problem are you trying to solve?
https://bugzilla.novell.com/show_bug.cgi?id=1107430
Yep ... or as I prefer https://bugzilla.opensuse.org/show_bug.cgi?id=1107430
here a version upgrade is a no-go
--
"Having a smoking section in a restaurant is like having
a peeing section in a swimming pool." -- Edward Burr
Loading...