Index: sources/canbus/messagedispatcher.cpp =================================================================== diff -u -rd2035a8728794afeefaa244bf8d1597926d945f5 -rbf645acccabb7b5a84801620c4f7fa0b0e6878e0 --- sources/canbus/messagedispatcher.cpp (.../messagedispatcher.cpp) (revision d2035a8728794afeefaa244bf8d1597926d945f5) +++ sources/canbus/messagedispatcher.cpp (.../messagedispatcher.cpp) (revision bf645acccabb7b5a84801620c4f7fa0b0e6878e0) @@ -1,16 +1,16 @@ /*! - * + * * Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. * \copyright * THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN * WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. - * + * * \file messagedispatcher.cpp * \author (last) Peter Lucia * \date (last) 29-Jun-2020 * \author (original) Behrouz NematiPour * \date (original) 09-Dec-2019 - * + * */ #include "messagedispatcher.h" @@ -301,6 +301,7 @@ } QByteArray mData; + if (! _interpreter.interpretMessage(vActionId, vData, mData)) { LOG_DEBUG(QString("Incorrect Message, can't be interpreted, %1").arg(Format::toHexString(vActionId))); // TODO : LOGGINF IMPROVEMENT return; @@ -318,10 +319,13 @@ #endif } + // coco begin validated: Has been tested manyally but in this function this can't be false because the message interpreter is doing the same validation. + // still checking here in case the logic has changed therefore buildFrame should still validate the message for developer safety. if ( ! _builder.buildFrames(vActionId, mData, frameList, mSequence) ) { LOG_DEBUG(QString("Incorrect Message can't be built")); // TODO : LOGGINF IMPROVEMENT return; } + // coco end if (mNeedsAcknow) { // NOTE : here vSequence should be used which is not negative // because when we get the Acknow it is not the negative