Checking network connection for OS X