mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
Move RAMLOG driver to drivers/syslog; Add ability to output debug information to any character device or file
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@4996 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -94,7 +94,7 @@ int lib_lowvprintf(const char *fmt, va_list ap)
|
||||
|
||||
/* Wrap the stdout in a stream object and let lib_vsprintf do the work. */
|
||||
|
||||
#if defined(CONFIG_RAMLOG_CONSOLE) || defined(CONFIG_RAMLOG_SYSLOG)
|
||||
#ifdef CONFIG_SYSLOG
|
||||
lib_syslogstream((FAR struct lib_outstream_s *)&stream);
|
||||
#else
|
||||
lib_lowoutstream((FAR struct lib_outstream_s *)&stream);
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include <nuttx/ramlog.h>
|
||||
#include <nuttx/syslog.h>
|
||||
|
||||
#include "lib_internal.h"
|
||||
|
||||
@@ -62,12 +62,10 @@
|
||||
|
||||
static void syslogstream_putc(FAR struct lib_outstream_s *this, int ch)
|
||||
{
|
||||
/* At present, the RAM log is the only supported logging device */
|
||||
/* Write the character to the supported logging device */
|
||||
|
||||
#ifdef CONFIG_RAMLOG_SYSLOG
|
||||
(void)ramlog_putc(ch);
|
||||
(void)syslog_putc(ch);
|
||||
this->nput++;
|
||||
#endif
|
||||
}
|
||||
|
||||
/****************************************************************************
|
||||
|
||||
Reference in New Issue
Block a user