}
string result = Marshal.PtrToStringAnsi(Value);
Interop.Libc.Free(Value);
- if (result == null)
+ if (result == null || result.Length == 0)
return System.Net.IPAddress.Parse("0.0.0.0");
return System.Net.IPAddress.Parse(result);
}
}
string result = Marshal.PtrToStringAnsi(Value);
Interop.Libc.Free(Value);
- if (result == null)
+ if (result == null || result.Length == 0)
return System.Net.IPAddress.Parse("0.0.0.0");
return System.Net.IPAddress.Parse(result);
}
}
string result = Marshal.PtrToStringAnsi(Value);
Interop.Libc.Free(Value);
- if (result == null)
+ if (result == null || result.Length == 0)
return System.Net.IPAddress.Parse("0.0.0.0");
return System.Net.IPAddress.Parse(result);
}
}
string result = Marshal.PtrToStringAnsi(Value);
Interop.Libc.Free(Value);
- if (result == null)
+ if (result == null || result.Length == 0)
return System.Net.IPAddress.Parse("0.0.0.0");
return System.Net.IPAddress.Parse(result);
}
}
string result = Marshal.PtrToStringAnsi(Value);
Interop.Libc.Free(Value);
- if (result == null)
+ if (result == null || result.Length == 0)
return System.Net.IPAddress.Parse("0.0.0.0");
return System.Net.IPAddress.Parse(result);
}
Log.Error(Globals.LogTag, "It failed to get the DHCP server address, " + (ConnectionError)ret);
}
- if (dhcpServer == null)
+ if (dhcpServer == null || dhcpServer.Length == 0)
{
return System.Net.IPAddress.Parse("0.0.0.0");
}