Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Address crashes on linput's use of printf.
On an empty line input, a C3 with UART console would panic while attempting to output the new Lua prompt. The backtrace shows a xQueueSemaphoreTake with uxItemSize==0 as the panic cause, deep inside the uart driver, invoked via vfs_uart and vfs_console layers, from printf. Similarly, the printf for outputting a backspace/erase sequence would also trigger a panic. This workaround (of not mixing fflush() with printf) is likely merely hiding a deeper issue, but it appears to be consistent. Plus, printf with no args and a user-supplied format string is a no-no and should be fixed anyway.
- Loading branch information