FastLED 3.9.15
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages

◆ StringHolder() [3/4]

fl::StringHolder::StringHolder ( const char * str,
size_t length )

Definition at line 179 of file str.cpp.

179 {
180 mData = (char *)malloc(length + 1);
181 if (mData) {
182 mLength = length;
183 memcpy(mData, str, mLength);
184 mData[mLength] = '\0';
185 } else {
186 mLength = 0;
187 }
189}
char * mData
Definition str.h:102
size_t length() const
Definition str.h:89
size_t mLength
Definition str.h:103
size_t mCapacity
Definition str.h:104

References length(), mCapacity, mData, and mLength.

+ Here is the call graph for this function: