syslog_rpmsg: head must bigger then tail when syslog_rpmsg_init
Signed-off-by: ligd <liguiding1@xiaomi.com>
This commit is contained in:
parent
2291f601ee
commit
5c33db4220
1 changed files with 4 additions and 0 deletions
|
|
@ -420,6 +420,10 @@ void syslog_rpmsg_init_early(FAR void *buffer, size_t size)
|
|||
{
|
||||
priv->head = priv->tail = 0;
|
||||
}
|
||||
else if (priv->head < priv->tail)
|
||||
{
|
||||
priv->head += priv->size;
|
||||
}
|
||||
}
|
||||
|
||||
int syslog_rpmsg_init(void)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue