net/ethoc: fix null dereference on error exit path