Fix liveness of buf
So that domain can point to it.
This commit is contained in:
parent
6df96f8148
commit
4d906e595d
1 changed files with 1 additions and 1 deletions
2
l2tpns.c
2
l2tpns.c
|
|
@ -4520,12 +4520,12 @@ static void stripdomain(char *host)
|
|||
{
|
||||
char *domain = 0;
|
||||
char _domain[1024];
|
||||
char buf[1024];
|
||||
|
||||
// strip off domain
|
||||
FILE *resolv = fopen("/etc/resolv.conf", "r");
|
||||
if (resolv)
|
||||
{
|
||||
char buf[1024];
|
||||
char *b;
|
||||
|
||||
while (fgets(buf, sizeof(buf), resolv))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue