From e0815858309f801d953d023b5322ef0b07f6046e Mon Sep 17 00:00:00 2001 From: Steve Checkoway Date: Fri, 28 Jul 2006 04:37:26 +0000 Subject: [PATCH] Add comment. --- stepmania/src/NoteDataUtil.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/stepmania/src/NoteDataUtil.cpp b/stepmania/src/NoteDataUtil.cpp index 6e97f4c7de..3f9a071d55 100644 --- a/stepmania/src/NoteDataUtil.cpp +++ b/stepmania/src/NoteDataUtil.cpp @@ -2050,6 +2050,10 @@ void NoteDataUtil::DeleteRows( NoteData &nd, int iStartIndex, int iRowsToDelete void NoteDataUtil::RemoveAllTapsOfType( NoteData& ndInOut, TapNote::Type typeToRemove ) { + /* Be very careful when deleting the tap notes. Erasing elements from maps using + * iterators invalidates only the iterator that is being erased. To that end, + * increment the iterator before deleting the elment of the map. + */ for( int t=0; t