UndoBuffer.cpp: Fix PVS 471

Fix 'fTypedText' is assigned values twice successively.

Change-Id: Ibadf2fced0f448441e541293d04b86bc14909c35
Reviewed-on: https://review.haiku-os.org/729
Reviewed-by: Jérôme Duval <[email protected]>
This commit is contained in:
Murai Takashi
2018-11-24 12:04:32 +00:00
committed by Jérôme Duval
parent bf98f7960d
commit a9002af95e
@@ -271,7 +271,6 @@ BTextView::TypingUndoBuffer::UndoSelf(BClipboard* clipboard)
int32 len = fTypedEnd - fTypedStart;
free(fTypedText);
fTypedText = NULL;
fTypedText = (char*)malloc(len);
memcpy(fTypedText, fTextView->Text() + fTypedStart, len);