Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 39836f1

Browse filesBrowse files
atanisoftme-no-dev
authored andcommitted
correct bounds checking in Print::printf to avoid corner case of len=64 (espressif#2204)
1 parent 25fd2d0 commit 39836f1
Copy full SHA for 39836f1

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed

‎cores/esp32/Print.cpp

Copy file name to clipboardExpand all lines: cores/esp32/Print.cpp
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ size_t Print::printf(const char *format, ...)
6363
len = vsnprintf(temp, len+1, format, arg);
6464
write((uint8_t*)temp, len);
6565
va_end(arg);
66-
if(len > 64){
66+
if(len >= sizeof(loc_buf)){
6767
delete[] temp;
6868
}
6969
return len;

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.