Skip to content

Commit de11b36

Browse files
committed
clang-tidy: muted "uninitialized pointer/field" in StringCopier
1 parent c4a4ed5 commit de11b36

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

src/ArduinoJson/StringStorage/StringCopier.hpp

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,12 @@ class StringCopier {
5555

5656
private:
5757
MemoryPool* _pool;
58+
59+
// These fields aren't initialized by the constructor but startString()
60+
//
61+
// NOLINTNEXTLINE(clang-analyzer-optin.cplusplus.UninitializedObject)
5862
char* _ptr;
59-
size_t _size;
60-
size_t _capacity;
63+
// NOLINTNEXTLINE(clang-analyzer-optin.cplusplus.UninitializedObject)
64+
size_t _size, _capacity;
6165
};
6266
} // namespace ARDUINOJSON_NAMESPACE

0 commit comments

Comments
 (0)