stm class: Fix an off-by-one in master array allocation