xiaoxiang781216 commented on code in PR #21787:
URL: https://github.com/apache/nuttx/pull/21787#discussion_r4553420344
##########
drivers/syslog/syslog_write.c:
##########
@@ -187,10 +187,14 @@ ssize_t syslog_write_foreach(int priority, FAR const char
*buffer,
continue;
}
- ret = write(channel, buffer + nwritten, head - nwritten);
- if (ret <= 0)
+ if (head > nwritten)
{
- continue;
+ ret = write(channel, buffer + nwritten,
Review Comment:
why write the same data to the channel twice
--
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]