stream: resolve code analysis warnings
Some checks failed
Doxygen Action / build (push) Has been cancelled
Some checks failed
Doxygen Action / build (push) Has been cancelled
Signed-off-by: Simon Rozman <simon@rozman.si>
This commit is contained in:
@@ -3585,7 +3585,7 @@ namespace stdex
|
||||
#endif
|
||||
size_t available = m_size - m_offset;
|
||||
if (length <= available) {
|
||||
stdex_assert(m_data || !length);
|
||||
stdex_assert(&m_data[m_offset] || !length);
|
||||
memcpy(data, &m_data[m_offset], length);
|
||||
m_offset += length;
|
||||
m_state = state_t::ok;
|
||||
@@ -3595,7 +3595,7 @@ namespace stdex
|
||||
m_state = state_t::eof;
|
||||
return 0;
|
||||
}
|
||||
stdex_assert(m_data || !available);
|
||||
stdex_assert(&m_data[m_offset] || !available);
|
||||
memcpy(data, &m_data[m_offset], available);
|
||||
m_offset += available;
|
||||
m_state = state_t::ok;
|
||||
@@ -3703,7 +3703,7 @@ namespace stdex
|
||||
if (!ok()) _Unlikely_
|
||||
return 0;
|
||||
}
|
||||
stdex_assert(m_data || !length);
|
||||
stdex_assert(&m_data[m_offset] || !length);
|
||||
memcpy(&m_data[m_offset], data, length);
|
||||
m_offset = end_offset;
|
||||
if (m_offset > m_size)
|
||||
@@ -3726,7 +3726,7 @@ namespace stdex
|
||||
if (!ok()) _Unlikely_
|
||||
return;
|
||||
}
|
||||
stdex_assert(m_data || !amount);
|
||||
stdex_assert(&m_data[m_offset] || !amount);
|
||||
memset(&m_data[m_offset], byte, amount);
|
||||
m_offset = end_offset;
|
||||
if (m_offset > m_size)
|
||||
|
Reference in New Issue
Block a user