linux-user: check return value of malloc()