Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

syslog: reslove crash because vmov.i32 instruction is not ready #4226

Merged
merged 1 commit into from
Jul 26, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions drivers/syslog/vsyslog.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,15 +72,9 @@ int nx_vsyslog(int priority, FAR const IPTR char *fmt, FAR va_list *ap)
struct tcb_s *tcb;
#endif
#ifdef CONFIG_SYSLOG_TIMESTAMP
struct timespec ts =
{
};

struct timespec ts;
#if defined(CONFIG_SYSLOG_TIMESTAMP_FORMATTED)
struct tm tm =
{
};

struct tm tm;
char date_buf[CONFIG_SYSLOG_TIMESTAMP_BUFFER];
#endif
#endif
Expand All @@ -92,6 +86,13 @@ int nx_vsyslog(int priority, FAR const IPTR char *fmt, FAR va_list *ap)
syslogstream_create(&stream);

#ifdef CONFIG_SYSLOG_TIMESTAMP
ts.tv_sec = 0;
ts.tv_nsec = 0;

#if defined(CONFIG_SYSLOG_TIMESTAMP_FORMATTED)
memset(&tm, 0, sizeof(tm));
#endif

/* Get the current time. Since debug output may be generated very early
* in the start-up sequence, hardware timer support may not yet be
* available.
Expand Down