mirror of
https://github.com/systemd/systemd
synced 2024-09-06 08:46:19 +00:00
journald: use structured initialization
This commit is contained in:
parent
2435269171
commit
d98580e438
|
@ -590,12 +590,14 @@ int stdout_stream_install(Server *s, int fd, StdoutStream **ret) {
|
|||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to generate stream ID: %m");
|
||||
|
||||
stream = new0(StdoutStream, 1);
|
||||
stream = new(StdoutStream, 1);
|
||||
if (!stream)
|
||||
return log_oom();
|
||||
|
||||
stream->fd = -1;
|
||||
stream->priority = LOG_INFO;
|
||||
*stream = (StdoutStream) {
|
||||
.fd = -1,
|
||||
.priority = LOG_INFO,
|
||||
};
|
||||
|
||||
xsprintf(stream->id_field, "_STREAM_ID=" SD_ID128_FORMAT_STR, SD_ID128_FORMAT_VAL(id));
|
||||
|
||||
|
|
Loading…
Reference in a new issue