diff options
author | falkTX <falktx@gmail.com> | 2018-08-26 09:48:40 +0200 |
---|---|---|
committer | falkTX <falktx@gmail.com> | 2018-08-26 09:48:40 +0200 |
commit | 4a4f95fc9f106882c2702fa22c2a574124a3f783 (patch) | |
tree | c91a85cc849ea7216fa08219454399bf4aa0ca6b /dgl/src | |
parent | dee2b4a8548ce7779d987ab88c2ebb9acbcfa1f1 (diff) |
Fix possible undefined variable in NanoVG::textBounds
Diffstat (limited to 'dgl/src')
-rw-r--r-- | dgl/src/NanoVG.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/dgl/src/NanoVG.cpp b/dgl/src/NanoVG.cpp index a54b02a8..3ef7b35d 100644 --- a/dgl/src/NanoVG.cpp +++ b/dgl/src/NanoVG.cpp @@ -863,7 +863,7 @@ float NanoVG::textBounds(float x, float y, const char* string, const char* end, if (fContext == nullptr) return 0.0f; DISTRHO_SAFE_ASSERT_RETURN(string != nullptr && string[0] != '\0', 0.0f); - float b[4]; + float b[4] = { 0.0f, 0.0f, 0.0f, 0.0f }; const float ret = nvgTextBounds(fContext, x, y, string, end, b); bounds = Rectangle<float>(b[0], b[1], b[2] - b[0], b[3] - b[1]); return ret; |