[PATCH 2/6] hostmon(): remove idx variable