Not all socket errors are covered by .wserr/.wsmsg. Check the value of $sockerr against the tables here.