syslog: Remove the lock from syslog_default_write

to avoid the problem when is called from interrupt/signal handler

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao 2022-07-14 15:50:37 +08:00 committed by Petro Karashchenko
parent 8254ad9159
commit 19f269e54b
1 changed files with 0 additions and 4 deletions

View File

@ -217,11 +217,7 @@ static ssize_t syslog_default_write(FAR struct syslog_channel_s *channel,
FAR const char *buffer, size_t buflen) FAR const char *buffer, size_t buflen)
{ {
#if defined(CONFIG_ARCH_LOWPUTC) #if defined(CONFIG_ARCH_LOWPUTC)
static sem_t sem = SEM_INITIALIZER(1);
nxsem_wait(&sem);
up_puts(buffer); up_puts(buffer);
nxsem_post(&sem);
#endif #endif
UNUSED(channel); UNUSED(channel);