summaryrefslogtreecommitdiff
path: root/src/libsystemd-network/sd-lldp.c
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2016-02-16 18:58:51 +0100
committerLennart Poettering <lennart@poettering.net>2016-02-20 22:42:29 +0100
commitccf86354354a378b314f66465bbb31f51b91864c (patch)
tree1fe13148de5894ba14514dd5af20b44e910a1597 /src/libsystemd-network/sd-lldp.c
parentc7d264ff9835ede8fae2f9edf8431fff8da19872 (diff)
libsystemd-network: don't abbreviate "callback" as "cb" needlessly
This isn't an excercise in creating APIs that are hard to understand, hence let's call a callback a callback.
Diffstat (limited to 'src/libsystemd-network/sd-lldp.c')
-rw-r--r--src/libsystemd-network/sd-lldp.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/libsystemd-network/sd-lldp.c b/src/libsystemd-network/sd-lldp.c
index 97fa5b23f8..3dfb08cd46 100644
--- a/src/libsystemd-network/sd-lldp.c
+++ b/src/libsystemd-network/sd-lldp.c
@@ -49,7 +49,7 @@ struct sd_lldp {
Prioq *by_expiry;
Hashmap *neighbour_mib;
- sd_lldp_cb_t cb;
+ sd_lldp_callback_t callback;
void *userdata;
@@ -105,8 +105,8 @@ static int lldp_receive_frame(sd_lldp *lldp, tlv_packet *tlv) {
if (r < 0)
goto out;
- if (lldp->cb)
- lldp->cb(lldp, SD_LLDP_EVENT_UPDATE_INFO, lldp->userdata);
+ if (lldp->callback)
+ lldp->callback(lldp, SD_LLDP_EVENT_UPDATE_INFO, lldp->userdata);
log_lldp("Packet added. MIB size: %d , PQ size: %d",
hashmap_size(lldp->neighbour_mib),
@@ -607,10 +607,10 @@ int sd_lldp_detach_event(sd_lldp *lldp) {
return 0;
}
-int sd_lldp_set_callback(sd_lldp *lldp, sd_lldp_cb_t cb, void *userdata) {
+int sd_lldp_set_callback(sd_lldp *lldp, sd_lldp_callback_t cb, void *userdata) {
assert_return(lldp, -EINVAL);
- lldp->cb = cb;
+ lldp->callback = cb;
lldp->userdata = userdata;
return 0;