removed part which is now not necessary anymore

This commit is contained in:
Robin Müller 2021-09-11 19:21:21 +02:00
parent 7c7a8a5df7
commit d36d849e69
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814

View File

@ -8,14 +8,6 @@ DleEncoder::~DleEncoder() {}
ReturnValue_t DleEncoder::encode(const uint8_t* sourceStream, ReturnValue_t DleEncoder::encode(const uint8_t* sourceStream,
size_t sourceLen, uint8_t* destStream, size_t maxDestLen, size_t sourceLen, uint8_t* destStream, size_t maxDestLen,
size_t* encodedLen, bool addStxEtx) { size_t* encodedLen, bool addStxEtx) {
if (addStxEtx) {
size_t currentIdx = 0;
if(not escapeStxEtx) {
destStream[currentIdx++] = DLE_CHAR;
}
}
if(escapeStxEtx) { if(escapeStxEtx) {
return encodeStreamEscaped(sourceStream, sourceLen, return encodeStreamEscaped(sourceStream, sourceLen,
destStream, maxDestLen, encodedLen, addStxEtx); destStream, maxDestLen, encodedLen, addStxEtx);