Fix draw mode crash.