spawn: fix a compiler warning (unused-variable)