ce07d65f1f
Change-Id: Ib31a8cb75f4cebcaa974b95097270362b3b26aef Reviewed-on: https://gerrit.libreoffice.org/52689 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
11 lines
411 B
Diff
11 lines
411 B
Diff
--- src/lib/libetonyek_xml.cpp
|
|
+++ src/lib/libetonyek_xml.cpp
|
|
@@ -35,7 +35,7 @@
|
|
unsigned long bytesRead = 0;
|
|
const unsigned char *const bytes = input->read((unsigned long)len, bytesRead);
|
|
|
|
- std::memcpy(buffer, bytes, static_cast<size_t>(bytesRead));
|
|
+ if (bytesRead != 0) std::memcpy(buffer, bytes, static_cast<size_t>(bytesRead));
|
|
return static_cast<int>(bytesRead);
|
|
}
|
|
catch (...)
|