Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-09-06 Thread Simon Kelley
Thanks everyone who's been working on this, and apologies for going MIA until now. Looking through the code, I think I can seen what's happening: memset(((char *)header) + qlen, 0, (limit - ((char *)header)) - qlen); Concentrate on the calculation of the length of the memset (limit

Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-08-29 Thread Kevin Darbyshire-Bryant
On 28/08/17 17:27, Christian Kujau wrote: On Mon, 28 Aug 2017, Christian Kujau wrote: On Mon, 28 Aug 2017, Kevin Darbyshire-Bryant wrote: My workaround is to only call memset if the difference between buffer begin and buffer limit is bigger than the query length, thus it retains Simon's

Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-08-29 Thread Kevin Darbyshire-Bryant
I've a *much* better fix for this. Will submit once I've collected someone from the station! Mad busy life, Kevin On 28/08/17 17:27, Christian Kujau wrote: On Mon, 28 Aug 2017, Christian Kujau wrote: On Mon, 28 Aug 2017, Kevin Darbyshire-Bryant wrote: My workaround is to only call memset

Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-08-28 Thread Christian Kujau
On Mon, 28 Aug 2017, Kevin Darbyshire-Bryant wrote: > My workaround is to only call memset if the difference between buffer begin > and buffer limit is bigger than the query length, thus it retains Simon's > intent of clearing memory most of the time but avoids the SIGSEGV trampling. Thanks, with

Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-08-28 Thread Christian Kujau
On Mon, 28 Aug 2017, Christian Kujau wrote: > On Mon, 28 Aug 2017, Kevin Darbyshire-Bryant wrote: > > My workaround is to only call memset if the difference between buffer begin > > and buffer limit is bigger than the query length, thus it retains Simon's > > intent of clearing memory most of the

Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-08-28 Thread Kevin Darbyshire-Bryant
On 27/08/17 08:18, Christian Kujau wrote: OK, so I should have done this in the first place and used git bisect to find out which commit in Dnsmasq introduced this behaviour: fa78573778cb23337f67f5d0c9de723169919047 is the first bad commit commit fa78573778cb23337f67f5d0c9de723169919047

Re: [Dnsmasq-discuss] reproducible segmentation fault - bisected!

2017-08-27 Thread Christian Kujau
OK, so I should have done this in the first place and used git bisect to find out which commit in Dnsmasq introduced this behaviour: fa78573778cb23337f67f5d0c9de723169919047 is the first bad commit commit fa78573778cb23337f67f5d0c9de723169919047 Author: Simon Kelley