projects
/
systemd
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d6c5d19
)
journal: use structured initalizer
author
Zbigniew Jędrzejewski-Szmek
<zbyszek@in.waw.pl>
Sun, 25 Mar 2018 20:44:05 +0000
(22:44 +0200)
committer
Zbigniew Jędrzejewski-Szmek
<zbyszek@in.waw.pl>
Mon, 26 Mar 2018 13:28:03 +0000
(15:28 +0200)
src/journal/catalog.c
patch
|
blob
|
history
diff --git
a/src/journal/catalog.c
b/src/journal/catalog.c
index 6775535b173f478d9809ab9fa6c4c752cda2f2a9..03d386cc64ecf9c8bfad3f266d9eed9b8b713dcc 100644
(file)
--- a/
src/journal/catalog.c
+++ b/
src/journal/catalog.c
@@
-592,13
+592,10
@@
static int open_mmap(const char *database, int *_fd, struct stat *_st, void **_p
}
static const char *find_id(void *p, sd_id128_t id) {
- CatalogItem
key, *f = NULL
;
+ CatalogItem
*f = NULL, key = { .id = id }
;
const CatalogHeader *h = p;
const char *loc;
- zero(key);
- key.id = id;
-
loc = setlocale(LC_MESSAGES, NULL);
if (loc && loc[0] && !streq(loc, "C") && !streq(loc, "POSIX")) {
strncpy(key.language, loc, sizeof(key.language));