2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-05 08:55:59 +00:00

Fix uninitialized values

- Use C++11 default member initializers

Signed-off-by: Veli-Matti Visuri <veli-matti.visuri@cerescon.fi> (github: visuve)
This commit is contained in:
visuve
2017-09-17 14:53:38 +03:00
committed by John Preston
parent 07106897a6
commit 8c92f42de3
3 changed files with 12 additions and 12 deletions

View File

@@ -717,7 +717,7 @@ enum { _MaxItemLength = 4096 };
struct BidiControl {
inline BidiControl(bool rtl)
: cCtx(0), base(rtl ? 1 : 0), level(rtl ? 1 : 0), override(false) {}
: base(rtl ? 1 : 0), level(rtl ? 1 : 0) {}
inline void embed(bool rtl, bool o = false) {
unsigned int toAdd = 1;
@@ -751,13 +751,13 @@ struct BidiControl {
}
struct {
unsigned int level;
bool override;
unsigned int level = 0;
bool override = false;
} ctx[_MaxBidiLevel];
unsigned int cCtx;
unsigned int cCtx = 0;
const unsigned int base;
unsigned int level;
bool override;
bool override = false;
};
static void eAppendItems(QScriptAnalysis *analysis, int &start, int &stop, const BidiControl &control, QChar::Direction dir) {