8000 BufferListPrint: Expose valid · troyhacks/ESPAsyncWebServer@d196a5f · GitHub
[go: up one dir, main page]

Skip to content

Commit d196a5f

Browse files
committed
BufferListPrint: Expose valid
1 parent 9e5cc01 commit d196a5f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/DynamicBuffer.h

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,9 @@ class BufferListPrint : public Print {
131131
size_t write(uint8_t c) {
132132
return this->write(&c, 1);
133133
}
134+
135+
bool valid() const { return _valid; };
136+
explicit operator bool() const { return valid(); };
134137
};
135138

136139
typedef BufferListPrint<DynamicBufferList> DynamicBufferListPrint;

0 commit comments

Comments
 (0)
0