matrix.printraw SegFault bug and fix