Commit d52f95ce authored by Ken Thomases's avatar Ken Thomases Committed by Alexandre Julliard

iphlpapi: Enable non-privileged ICMP (ping) on Mac OS X.

parent e814147b
......@@ -153,6 +153,11 @@ HANDLE WINAPI IcmpCreateFile(VOID)
icmp_t* icp;
int sid=socket(AF_INET,SOCK_RAW,IPPROTO_ICMP);
if (sid < 0)
{
/* Mac OS X supports non-privileged ICMP via SOCK_DGRAM type. */
sid=socket(AF_INET,SOCK_DGRAM,IPPROTO_ICMP);
}
if (sid < 0) {
ERR_(winediag)("Failed to use ICMP (network ping), this requires special permissions.\n");
SetLastError(ERROR_ACCESS_DENIED);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment