Any error in the initial snmp_open() such as
an unknown host results in a core dump. This
is because a NULL is passed to the subsequent
snmp_error() whereas the snmp_session should be passed
snmp_errstring(snmp_errno) also seems to not give the
correct error string. Replaced this with by errstr.