mirror of
https://github.com/pi-hole/dnsmasq.git
synced 2025-12-20 02:38:32 +00:00
Fix FTBFS with NO_DHCP.
This commit is contained in:
@@ -3,6 +3,10 @@ version 2.65
|
|||||||
TCP which are not for A and AAAA and which were directed to
|
TCP which are not for A and AAAA and which were directed to
|
||||||
non-default servers. Thanks to Niax for the bug report.
|
non-default servers. Thanks to Niax for the bug report.
|
||||||
|
|
||||||
|
Fix failure to build with DHCP support excluded. Thanks to
|
||||||
|
Gustavo Zacarias for the patch.
|
||||||
|
|
||||||
|
|
||||||
version 2.64
|
version 2.64
|
||||||
Handle DHCP FQDN options with all flag bits zero and
|
Handle DHCP FQDN options with all flag bits zero and
|
||||||
--dhcp-client-update set. Thanks to Bernd Krumbroeck for
|
--dhcp-client-update set. Thanks to Bernd Krumbroeck for
|
||||||
|
|||||||
36
src/option.c
36
src/option.c
@@ -623,24 +623,6 @@ static void do_usage(void)
|
|||||||
|
|
||||||
#define ret_err(x) do { strcpy(errstr, (x)); return 0; } while (0)
|
#define ret_err(x) do { strcpy(errstr, (x)); return 0; } while (0)
|
||||||
|
|
||||||
#ifdef HAVE_DHCP
|
|
||||||
|
|
||||||
static int is_tag_prefix(char *arg)
|
|
||||||
{
|
|
||||||
if (arg && (strstr(arg, "net:") == arg || strstr(arg, "tag:") == arg))
|
|
||||||
return 1;
|
|
||||||
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
static char *set_prefix(char *arg)
|
|
||||||
{
|
|
||||||
if (strstr(arg, "set:") == arg)
|
|
||||||
return arg+4;
|
|
||||||
|
|
||||||
return arg;
|
|
||||||
}
|
|
||||||
|
|
||||||
char *parse_server(char *arg, union mysockaddr *addr, union mysockaddr *source_addr, char *interface, int *flags)
|
char *parse_server(char *arg, union mysockaddr *addr, union mysockaddr *source_addr, char *interface, int *flags)
|
||||||
{
|
{
|
||||||
int source_port = 0, serv_port = NAMESERVER_PORT;
|
int source_port = 0, serv_port = NAMESERVER_PORT;
|
||||||
@@ -728,6 +710,24 @@ char *parse_server(char *arg, union mysockaddr *addr, union mysockaddr *source_a
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef HAVE_DHCP
|
||||||
|
|
||||||
|
static int is_tag_prefix(char *arg)
|
||||||
|
{
|
||||||
|
if (arg && (strstr(arg, "net:") == arg || strstr(arg, "tag:") == arg))
|
||||||
|
return 1;
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
static char *set_prefix(char *arg)
|
||||||
|
{
|
||||||
|
if (strstr(arg, "set:") == arg)
|
||||||
|
return arg+4;
|
||||||
|
|
||||||
|
return arg;
|
||||||
|
}
|
||||||
|
|
||||||
/* This is too insanely large to keep in-line in the switch */
|
/* This is too insanely large to keep in-line in the switch */
|
||||||
static int parse_dhcp_opt(char *errstr, char *arg, int flags)
|
static int parse_dhcp_opt(char *errstr, char *arg, int flags)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user