fix crash at undo in digitize
Merge pull request #818 from 3nids/undodigitize

fix crash at undo in digitize