projects
/
systemd
/
.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
494ef16
)
resolve: shorten code a bit
author
Yu Watanabe
<watanabe.yu+github@gmail.com>
Sat, 10 Dec 2022 01:25:38 +0000
(10:25 +0900)
committer
Yu Watanabe
<watanabe.yu+github@gmail.com>
Sat, 10 Dec 2022 01:32:29 +0000
(10:32 +0900)
src/resolve/resolved-dns-rr.c
patch
|
blob
|
history
diff --git
a/src/resolve/resolved-dns-rr.c
b/src/resolve/resolved-dns-rr.c
index 5f890f950938a2e8685ef7e8d0e7ea3d74513952..ce9cecf118c70596fad7c86cecc014601e9a30ad 100644
(file)
--- a/
src/resolve/resolved-dns-rr.c
+++ b/
src/resolve/resolved-dns-rr.c
@@
-1801,10
+1801,8
@@
DnsTxtItem *dns_txt_item_copy(DnsTxtItem *first) {
DnsTxtItem *j;
j = memdup(i, offsetof(DnsTxtItem, data) + i->length + 1);
- if (!j) {
- dns_txt_item_free_all(copy);
- return NULL;
- }
+ if (!j)
+ return dns_txt_item_free_all(copy);
LIST_INSERT_AFTER(items, copy, end, j);
end = j;