From 7cc07d842cd1912baa932548354f658753559c84 Mon Sep 17 00:00:00 2001 From: Christophe Dumez Date: Sun, 3 Jan 2010 19:03:05 +0000 Subject: [PATCH] - Put back the ASSERT (it should no longer be hit) --- src/transferlistfilterswidget.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/transferlistfilterswidget.h b/src/transferlistfilterswidget.h index 8ed8dd545..51b444ba9 100644 --- a/src/transferlistfilterswidget.h +++ b/src/transferlistfilterswidget.h @@ -332,8 +332,8 @@ protected slots: } void torrentAdded(QModelIndex index) { + Q_ASSERT(index.isValid()); if(!index.isValid()) return; - //Q_ASSERT(index.isValid()); QString label = transferList->getSourceModel()->index(index.row(), TR_LABEL).data(Qt::DisplayRole).toString().trimmed(); qDebug("New torrent was added with label: %s", label.toLocal8Bit().data()); if(!label.isEmpty()) { @@ -357,6 +357,7 @@ protected slots: } void torrentAboutToBeDeleted(QModelIndex index) { + if(!index.isValid()) return; Q_ASSERT(index.isValid()); QString label = transferList->model()->index(index.row(), TR_LABEL).data(Qt::DisplayRole).toString().trimmed(); if(!label.isEmpty()) {