mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2026-06-08 18:14:53 +00:00
tools: acrn-crashlog: fix format-security warning
We will get the following warning when build acrn. This patch fix it.
No functional change.
In file included from log_sys.c:8:0:
log_sys.c: In function ‘do_log’:
log_sys.c:44:26: warning: format not a string literal and no format arguments [-Wformat-security]
sd_journal_print(level, log);
^
Signed-off-by: Kaige Fu <kaige.fu@intel.com>
Acked-by: Eddie Dong <eddie.dong@intel.com>
Acked-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
@@ -45,5 +45,5 @@ void do_log(const int level,
|
||||
log[sizeof(log) - 1] = 0;
|
||||
va_end(args);
|
||||
|
||||
sd_journal_print(level, log);
|
||||
sd_journal_print(level, "%s", log);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user