mirror of
https://github.com/systemd/systemd.git
synced 2025-01-27 18:04:05 +03:00
resolve: add missing assertion
This commit is contained in:
parent
14822ede9f
commit
068ef623bd
@ -1814,6 +1814,8 @@ DnsTxtItem *dns_txt_item_copy(DnsTxtItem *first) {
|
||||
int dns_txt_item_new_empty(DnsTxtItem **ret) {
|
||||
DnsTxtItem *i;
|
||||
|
||||
assert(ret);
|
||||
|
||||
/* RFC 6763, section 6.1 suggests to treat
|
||||
* empty TXT RRs as equivalent to a TXT record
|
||||
* with a single empty string. */
|
||||
@ -1823,7 +1825,6 @@ int dns_txt_item_new_empty(DnsTxtItem **ret) {
|
||||
return -ENOMEM;
|
||||
|
||||
*ret = i;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user