We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a8c4be6 commit 794a440Copy full SHA for 794a440
src/CppSQLite3.cpp
@@ -57,7 +57,9 @@ SQLite3Memory::SQLite3Memory(SQLite3Memory const &other)
57
throw CppSQLite3Exception(CPPSQLITE_ERROR, ALLOCATION_ERROR_MESSAGE,
58
DONT_DELETE_MSG);
59
}
60
- std::memcpy(mpBuf, other.mpBuf, mnBufferLen);
+ if (mnBufferLen > 0) {
61
+ std::memcpy(mpBuf, other.mpBuf, mnBufferLen);
62
+ }
63
64
65
SQLite3Memory &SQLite3Memory::operator=(SQLite3Memory const &lhs) {
0 commit comments