Warning raised by Valgrind

This commit is contained in:
bsongis
2014-07-01 22:53:27 +02:00
parent 194a635800
commit 7162ab5399
@@ -2804,10 +2804,12 @@ void OpenTxGeneralData::beforeExport()
sum += generalData.calibSpanPos[i]; sum += generalData.calibSpanPos[i];
if (++count == 12) break; if (++count == 12) break;
} }
for (int i=0; i<4; i++) { if (IS_TARANIS(board)) {
potsType[i] = generalData.potsType[i]; for (int i=0; i<4; i++) {
if (i<2 && potsType[i] == 1) potsType[i] = generalData.potsType[i];
potsType[i] = 0; if (i<2 && potsType[i] == 1)
potsType[i] = 0;
}
} }
} }
else { else {
@@ -2821,9 +2823,11 @@ void OpenTxGeneralData::beforeExport()
void OpenTxGeneralData::afterImport() void OpenTxGeneralData::afterImport()
{ {
for (int i=0; i<4; i++) { if (IS_TARANIS(board)) {
generalData.potsType[i] = potsType[i]; for (int i=0; i<4; i++) {
if (i<2 && potsType[i] == 0) generalData.potsType[i] = potsType[i];
generalData.potsType[i] = 1; if (i<2 && potsType[i] == 0)
generalData.potsType[i] = 1;
}
} }
} }