mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-19 18:28:25 +00:00
Fix crash parsing a --synth-domain with no prefix.
Problem introduced in 2.79/6b2b564ac34cb3c862f168e6b1457f9f0b9ca69c
This commit is contained in:
@@ -41,8 +41,11 @@ version 2.80
|
|||||||
Fix missing fatal errors with some malformed options
|
Fix missing fatal errors with some malformed options
|
||||||
(server, local, address, rebind-domain-ok, ipset, alias).
|
(server, local, address, rebind-domain-ok, ipset, alias).
|
||||||
Thanks to Eugene Lozovoy for spotting the problem.
|
Thanks to Eugene Lozovoy for spotting the problem.
|
||||||
|
|
||||||
|
Fix crash on startup with a --synth-domain which has no prefix.
|
||||||
|
Introduced in 2.79. Thanks to Andreas Engel for the bug report.
|
||||||
|
|
||||||
|
|
||||||
version 2.79
|
version 2.79
|
||||||
Fix parsing of CNAME arguments, which are confused by extra spaces.
|
Fix parsing of CNAME arguments, which are confused by extra spaces.
|
||||||
Thanks to Diego Aguirre for spotting the bug.
|
Thanks to Diego Aguirre for spotting the bug.
|
||||||
|
|||||||
@@ -2232,7 +2232,9 @@ static int one_opt(int option, char *arg, char *errstr, char *gen_err, int comma
|
|||||||
char *star;
|
char *star;
|
||||||
new->next = daemon->synth_domains;
|
new->next = daemon->synth_domains;
|
||||||
daemon->synth_domains = new;
|
daemon->synth_domains = new;
|
||||||
if ((star = strrchr(new->prefix, '*')) && *(star+1) == 0)
|
if (new->prefix &&
|
||||||
|
(star = strrchr(new->prefix, '*'))
|
||||||
|
&& *(star+1) == 0)
|
||||||
{
|
{
|
||||||
*star = 0;
|
*star = 0;
|
||||||
new->indexed = 1;
|
new->indexed = 1;
|
||||||
|
|||||||
Reference in New Issue
Block a user