[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Which commit for a bug in 4.3.48 which is fixed in 4.4.23
From: |
Eduardo A . Bustamante López |
Subject: |
Re: Which commit for a bug in 4.3.48 which is fixed in 4.4.23 |
Date: |
Fri, 21 Sep 2018 09:52:29 -0700 |
User-agent: |
Mutt/1.10.1 (2018-07-13) |
On Fri, Sep 21, 2018 at 01:11:38PM +0200, Dr. Werner Fink wrote:
> 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
+ <izaberina@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);