Fix crash at startup when Device is not specified on OS X.
This commit is contained in:
parent
8afb52a39a
commit
a0a8f8f81f
1 changed files with 1 additions and 1 deletions
|
@ -147,7 +147,7 @@ static bool setup_device(void) {
|
|||
}
|
||||
} else {
|
||||
#ifdef HAVE_NET_IF_UTUN_H
|
||||
if(strncmp(device, "utun", 4) == 0 || strncmp(device, "/dev/utun", 9) == 0)
|
||||
if(device && (strncmp(device, "utun", 4) == 0 || strncmp(device, "/dev/utun", 9) == 0))
|
||||
device_type = DEVICE_TYPE_UTUN;
|
||||
else
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue