net/ice/base: fix memory handling