fix error reporting for getNetworkInfo()
Merge pull request #1412 from christav/getNetworkInfo-fix

fix error reporting for getNetworkInfo()