| 1 | Index: libs/libmythtv/channelbase.cpp
|
|---|
| 2 | ===================================================================
|
|---|
| 3 | --- libs/libmythtv/channelbase.cpp (revision 8406)
|
|---|
| 4 | +++ libs/libmythtv/channelbase.cpp (working copy)
|
|---|
| 5 | @@ -413,17 +413,17 @@
|
|---|
| 6 | const QMap<int, QString> &startChanNum)
|
|---|
| 7 | {
|
|---|
| 8 | int cardid = GetCardID();
|
|---|
| 9 | - QString querystr, input;
|
|---|
| 10 |
|
|---|
| 11 | MSqlQuery query(MSqlQuery::InitCon());
|
|---|
| 12 |
|
|---|
| 13 | - for (int i = 0;; i++)
|
|---|
| 14 | + QMap<int, QString>::const_iterator it = startChanNum.begin();
|
|---|
| 15 | +
|
|---|
| 16 | + for (; it != startChanNum.end(); ++it)
|
|---|
| 17 | {
|
|---|
| 18 | - input = GetInputByNum(i);
|
|---|
| 19 | - if (input.isEmpty())
|
|---|
| 20 | - break;
|
|---|
| 21 | + int i = it.key();
|
|---|
| 22 | + QString input = GetInputByNum(i);
|
|---|
| 23 |
|
|---|
| 24 | - if (startChanNum[i].isEmpty())
|
|---|
| 25 | + if (input.isEmpty() || startChanNum[i].isEmpty())
|
|---|
| 26 | continue;
|
|---|
| 27 |
|
|---|
| 28 | query.prepare(
|
|---|