jerpelea opened a new pull request, #21257: URL: https://github.com/apache/nuttx/pull/21257
## Summary A line buffered stream is flushed at a newline only by fputc(), fputs() and puts(). printf() writes through fwrite(), so a line that printf() writes to a line buffered stream (stdout or stderr on a terminal) stays in the buffer until the buffer is full or the program exits. The output of stderr comes after later lines of stdout, and complete lines are lost when the program ends with _exit() or abort(). This PR flushes the stream in lib_fwrite_unlocked() when the stream is line buffered and the data holds a newline. The first commit fixes an old nxstyle error in lib_libfwrite.c (a missing blank line), so that checkpatch passes on the file. ## Impact RELEASE ## Testing CI -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
