Re: smtpd: malloc+strlcpy -> strndup

2018-09-05 Thread Gilles Chehade
On Mon, Sep 03, 2018 at 11:43:02PM +0800, Michael Mikonos wrote: > On Mon, Sep 03, 2018 at 02:24:49PM +0800, Michael Mikonos wrote: > > On Sat, Sep 01, 2018 at 11:31:49PM +0200, Gilles Chehade wrote: > > > On Sat, Sep 01, 2018 at 09:20:59PM +0800, Michael Mikonos wrote: > > > > Hello, > > > > > >

Re: smtpd: malloc+strlcpy -> strndup

2018-09-03 Thread Michael Mikonos
On Mon, Sep 03, 2018 at 02:24:49PM +0800, Michael Mikonos wrote: > On Sat, Sep 01, 2018 at 11:31:49PM +0200, Gilles Chehade wrote: > > On Sat, Sep 01, 2018 at 09:20:59PM +0800, Michael Mikonos wrote: > > > Hello, > > > > > > Replace a malloc+strlcpy with strndup in cmdline_symset(). > > >

Re: smtpd: malloc+strlcpy -> strndup

2018-09-03 Thread Michael Mikonos
On Sat, Sep 01, 2018 at 11:31:49PM +0200, Gilles Chehade wrote: > On Sat, Sep 01, 2018 at 09:20:59PM +0800, Michael Mikonos wrote: > > Hello, > > > > Replace a malloc+strlcpy with strndup in cmdline_symset(). > > Parameter s is a "keyname=value" string and sym is the > > "keyname" part. > > > >

Re: smtpd: malloc+strlcpy -> strndup

2018-09-01 Thread Gilles Chehade
On Sat, Sep 01, 2018 at 09:20:59PM +0800, Michael Mikonos wrote: > Hello, > > Replace a malloc+strlcpy with strndup in cmdline_symset(). > Parameter s is a "keyname=value" string and sym is the > "keyname" part. > > If s is "=value", sym will be an empty string. > The patch doesn't change this

smtpd: malloc+strlcpy -> strndup

2018-09-01 Thread Michael Mikonos
Hello, Replace a malloc+strlcpy with strndup in cmdline_symset(). Parameter s is a "keyname=value" string and sym is the "keyname" part. If s is "=value", sym will be an empty string. The patch doesn't change this behaviour although it might be undesirable to call symset() with an empty string.