A typo
V501 There are identical sub-expressions ‘mimeData->hasFormat(QLatin1String(“application/x-kde-ark-dndextract-service”))’ to the left and to the right of the ‘&&’ operator. iconview.cpp 2357
void IconView::dropEvent(QGraphicsSceneDragDropEvent *event) { .... if (mimeData->hasFormat(QLatin1String( "application/x-kde-ark-dndextract-service")) && mimeData->hasFormat(QLatin1String( "application/x-kde-ark-dndextract-service"))) { const QString remoteDBusClient = mimeData->data( QLatin1String("application/x-kde-ark-dndextract-service")); const QString remoteDBusPath = mimeData->data( QLatin1String("application/x-kde-ark-dndextract-path")); .... } .... }
The analyzer has detected two identical conditional expressions. The conditional operator’s body suggests that the condition should have looked like this:
if (mimeData->hasFormat(QLatin1String( "application/x-kde-ark-dndextract-service")) && mimeData->hasFormat(QLatin1String( "application/x-kde-ark-dndextract-path "))) { .... }
Please click here to see more bugs from this project.