Fixes buffer overrun in Matrix's assignment operator.