mirror of
git://git.savannah.nongnu.org/eliot.git
synced 2025-01-13 20:03:23 +01:00
Do not write unitialized bytes in the dictionary header.
These bytes wouldn't be read anyway, but it is cleaner and makes valgrind happy.
This commit is contained in:
parent
02249c214e
commit
2663a62ecb
1 changed files with 12 additions and 0 deletions
|
@ -113,6 +113,12 @@ struct Dict_header_old
|
||||||
/** Extension of the old format (used in version 1) */
|
/** Extension of the old format (used in version 1) */
|
||||||
struct Dict_header_ext
|
struct Dict_header_ext
|
||||||
{
|
{
|
||||||
|
Dict_header_ext()
|
||||||
|
{
|
||||||
|
// Make sure we won't write uninitialized bytes
|
||||||
|
memset(this, 0, sizeof(*this));
|
||||||
|
}
|
||||||
|
|
||||||
// Time when the dictionary was compressed
|
// Time when the dictionary was compressed
|
||||||
// (number of seconds since the Epoch)
|
// (number of seconds since the Epoch)
|
||||||
uint64_t compressDate;
|
uint64_t compressDate;
|
||||||
|
@ -166,6 +172,12 @@ struct Dict_header_ext
|
||||||
/** Extension of the extension :-) (used in version 2) */
|
/** Extension of the extension :-) (used in version 2) */
|
||||||
struct Dict_header_ext_2
|
struct Dict_header_ext_2
|
||||||
{
|
{
|
||||||
|
Dict_header_ext_2()
|
||||||
|
{
|
||||||
|
// Make sure we won't write uninitialized bytes
|
||||||
|
memset(this, 0, sizeof(*this));
|
||||||
|
}
|
||||||
|
|
||||||
// Additional information concerning the display strings and the
|
// Additional information concerning the display strings and the
|
||||||
// alternative input strings of the letters
|
// alternative input strings of the letters
|
||||||
char displayAndInput[_MAX_DISPLAY_INPUT_SIZE_];
|
char displayAndInput[_MAX_DISPLAY_INPUT_SIZE_];
|
||||||
|
|
Loading…
Reference in a new issue