Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/BERDecode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ int OIDType::fromBuffer(const uint8_t *buf, size_t max_len){
this->data.assign(dataPtr, dataPtr + _length);
this->valid = true;

return _length + 2;
return _length + j;
}

static inline void long_to_buf(char* buf, long l, short r = 0){
Expand Down Expand Up @@ -208,7 +208,7 @@ int Counter64::fromBuffer(const uint8_t *buf, size_t max_len){
_value = _value | *ptr++;
tempLength--;
}
return _length + 2;
return _length + i;
}

std::shared_ptr<BER_CONTAINER> ComplexType::createObjectForType(ASN_TYPE valueType){
Expand Down Expand Up @@ -290,5 +290,5 @@ int ComplexType::fromBuffer(const uint8_t *buf, size_t max_len){
ptr += used_length;
i += used_length;
}
return _length + 2;
return _length + j;
}