summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/libsystemd-network/sd-dhcp-client.c2
-rw-r--r--src/libsystemd-network/sd-dhcp-lease.c2
-rw-r--r--src/libsystemd-network/sd-dhcp6-client.c2
-rw-r--r--src/libsystemd-network/sd-dhcp6-lease.c2
-rw-r--r--src/libsystemd-network/sd-icmp6-nd.c2
-rw-r--r--src/libsystemd-network/sd-ipv4ll.c2
-rw-r--r--src/libsystemd/sd-hwdb/sd-hwdb.c2
-rw-r--r--src/libsystemd/sd-rtnl/rtnl-message.c2
-rw-r--r--src/libsystemd/sd-rtnl/sd-rtnl.c2
9 files changed, 9 insertions, 9 deletions
diff --git a/src/libsystemd-network/sd-dhcp-client.c b/src/libsystemd-network/sd-dhcp-client.c
index c8a724f27e..dbecad4d9c 100644
--- a/src/libsystemd-network/sd-dhcp-client.c
+++ b/src/libsystemd-network/sd-dhcp-client.c
@@ -1672,7 +1672,7 @@ sd_dhcp_client *sd_dhcp_client_ref(sd_dhcp_client *client) {
}
sd_dhcp_client *sd_dhcp_client_unref(sd_dhcp_client *client) {
- if (client && REFCNT_DEC(client->n_ref) <= 0) {
+ if (client && REFCNT_DEC(client->n_ref) == 0) {
log_dhcp_client(client, "FREE");
client_initialize(client);
diff --git a/src/libsystemd-network/sd-dhcp-lease.c b/src/libsystemd-network/sd-dhcp-lease.c
index 22a4af6837..00fef164b0 100644
--- a/src/libsystemd-network/sd-dhcp-lease.c
+++ b/src/libsystemd-network/sd-dhcp-lease.c
@@ -193,7 +193,7 @@ sd_dhcp_lease *sd_dhcp_lease_ref(sd_dhcp_lease *lease) {
}
sd_dhcp_lease *sd_dhcp_lease_unref(sd_dhcp_lease *lease) {
- if (lease && REFCNT_DEC(lease->n_ref) <= 0) {
+ if (lease && REFCNT_DEC(lease->n_ref) == 0) {
free(lease->hostname);
free(lease->domainname);
free(lease->dns);
diff --git a/src/libsystemd-network/sd-dhcp6-client.c b/src/libsystemd-network/sd-dhcp6-client.c
index 017371e837..2bbed7d91f 100644
--- a/src/libsystemd-network/sd-dhcp6-client.c
+++ b/src/libsystemd-network/sd-dhcp6-client.c
@@ -1254,7 +1254,7 @@ sd_dhcp6_client *sd_dhcp6_client_ref(sd_dhcp6_client *client) {
}
sd_dhcp6_client *sd_dhcp6_client_unref(sd_dhcp6_client *client) {
- if (client && REFCNT_DEC(client->n_ref) <= 0) {
+ if (client && REFCNT_DEC(client->n_ref) == 0) {
client_reset(client);
sd_dhcp6_client_detach_event(client);
diff --git a/src/libsystemd-network/sd-dhcp6-lease.c b/src/libsystemd-network/sd-dhcp6-lease.c
index 8960fac92f..78e1589286 100644
--- a/src/libsystemd-network/sd-dhcp6-lease.c
+++ b/src/libsystemd-network/sd-dhcp6-lease.c
@@ -195,7 +195,7 @@ sd_dhcp6_lease *sd_dhcp6_lease_ref(sd_dhcp6_lease *lease) {
}
sd_dhcp6_lease *sd_dhcp6_lease_unref(sd_dhcp6_lease *lease) {
- if (lease && REFCNT_DEC(lease->n_ref) <= 0) {
+ if (lease && REFCNT_DEC(lease->n_ref) == 0) {
free(lease->serverid);
dhcp6_lease_free_ia(&lease->ia);
diff --git a/src/libsystemd-network/sd-icmp6-nd.c b/src/libsystemd-network/sd-icmp6-nd.c
index fbaf093ad8..d2bff8fcf6 100644
--- a/src/libsystemd-network/sd-icmp6-nd.c
+++ b/src/libsystemd-network/sd-icmp6-nd.c
@@ -145,7 +145,7 @@ static int icmp6_nd_init(sd_icmp6_nd *nd) {
}
sd_icmp6_nd *sd_icmp6_nd_unref(sd_icmp6_nd *nd) {
- if (nd && REFCNT_DEC(nd->n_ref) <= 0) {
+ if (nd && REFCNT_DEC(nd->n_ref) == 0) {
icmp6_nd_init(nd);
sd_icmp6_nd_detach_event(nd);
diff --git a/src/libsystemd-network/sd-ipv4ll.c b/src/libsystemd-network/sd-ipv4ll.c
index 8626d4afa9..02f2f9e0a9 100644
--- a/src/libsystemd-network/sd-ipv4ll.c
+++ b/src/libsystemd-network/sd-ipv4ll.c
@@ -605,7 +605,7 @@ sd_ipv4ll *sd_ipv4ll_ref(sd_ipv4ll *ll) {
}
sd_ipv4ll *sd_ipv4ll_unref(sd_ipv4ll *ll) {
- if (ll && REFCNT_DEC(ll->n_ref) <= 0) {
+ if (ll && REFCNT_DEC(ll->n_ref) == 0) {
ll->receive_message =
sd_event_source_unref(ll->receive_message);
ll->fd = safe_close(ll->fd);
diff --git a/src/libsystemd/sd-hwdb/sd-hwdb.c b/src/libsystemd/sd-hwdb/sd-hwdb.c
index 7444ab5f12..a16807f9d5 100644
--- a/src/libsystemd/sd-hwdb/sd-hwdb.c
+++ b/src/libsystemd/sd-hwdb/sd-hwdb.c
@@ -344,7 +344,7 @@ _public_ sd_hwdb *sd_hwdb_ref(sd_hwdb *hwdb) {
}
_public_ sd_hwdb *sd_hwdb_unref(sd_hwdb *hwdb) {
- if (hwdb && REFCNT_DEC(hwdb->n_ref) <= 0) {
+ if (hwdb && REFCNT_DEC(hwdb->n_ref) == 0) {
if (hwdb->map)
munmap((void *)hwdb->map, hwdb->st.st_size);
if (hwdb->f)
diff --git a/src/libsystemd/sd-rtnl/rtnl-message.c b/src/libsystemd/sd-rtnl/rtnl-message.c
index a089fae044..06a7a4b83a 100644
--- a/src/libsystemd/sd-rtnl/rtnl-message.c
+++ b/src/libsystemd/sd-rtnl/rtnl-message.c
@@ -586,7 +586,7 @@ sd_rtnl_message *sd_rtnl_message_ref(sd_rtnl_message *m) {
}
sd_rtnl_message *sd_rtnl_message_unref(sd_rtnl_message *m) {
- if (m && REFCNT_DEC(m->n_ref) <= 0) {
+ if (m && REFCNT_DEC(m->n_ref) == 0) {
unsigned i;
free(m->hdr);
diff --git a/src/libsystemd/sd-rtnl/sd-rtnl.c b/src/libsystemd/sd-rtnl/sd-rtnl.c
index a45ca5e9f5..5778ea53c0 100644
--- a/src/libsystemd/sd-rtnl/sd-rtnl.c
+++ b/src/libsystemd/sd-rtnl/sd-rtnl.c
@@ -187,7 +187,7 @@ sd_rtnl *sd_rtnl_unref(sd_rtnl *rtnl) {
assert_return(!rtnl_pid_changed(rtnl), NULL);
- if (REFCNT_DEC(rtnl->n_ref) <= 0) {
+ if (REFCNT_DEC(rtnl->n_ref) == 0) {
struct match_callback *f;
unsigned i;