comparison data/model/SparseModel.h @ 978:9f526ddc6165

Fix memory leak (from coverity scan)
author Chris Cannam
date Wed, 03 Sep 2014 13:08:32 +0100
parents df82da55e86a
children cc27f35aa75c
comparison
equal deleted inserted replaced
977:048173126e71 978:9f526ddc6165
361 return command->finish(); 361 return command->finish();
362 } 362 }
363 363
364 virtual Command *getRemoveRowCommand(int row) 364 virtual Command *getRemoveRowCommand(int row)
365 { 365 {
366 EditCommand *command = new EditCommand(this, tr("Delete Data Point"));
367 PointListIterator i = getPointListIteratorForRow(row); 366 PointListIterator i = getPointListIteratorForRow(row);
368 if (i == m_points.end()) return 0; 367 if (i == m_points.end()) return 0;
368 EditCommand *command = new EditCommand(this, tr("Delete Data Point"));
369 command->deletePoint(*i); 369 command->deletePoint(*i);
370 return command->finish(); 370 return command->finish();
371 } 371 }
372 372
373 protected: 373 protected: