syslogstream : init value for lib_syslograwstream_s.last_ch

Signed-off-by: xucheng5 <xucheng5@xiaomi.com>
This commit is contained in:
xucheng5 2024-09-05 15:40:58 +08:00 committed by archer
parent 45277dac3e
commit 887c6c8716

View file

@ -260,6 +260,7 @@ void lib_syslograwstream_open(FAR struct lib_syslograwstream_s *stream)
stream->common.putc = syslograwstream_putc; stream->common.putc = syslograwstream_putc;
stream->common.puts = syslograwstream_puts; stream->common.puts = syslograwstream_puts;
stream->common.nput = 0; stream->common.nput = 0;
stream->last_ch = '\0';
#ifdef CONFIG_SYSLOG_BUFFER #ifdef CONFIG_SYSLOG_BUFFER
stream->common.flush = syslograwstream_flush; stream->common.flush = syslograwstream_flush;