mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-01-11 04:00:20 +01:00
netlink: don't require a callback argument in nl_recvmsgs()
This commit is contained in:
parent
0713a6996c
commit
7a105c2191
1 changed files with 2 additions and 2 deletions
|
|
@ -1055,7 +1055,7 @@ nl_wait_for_ack (struct nl_sock *sk,
|
|||
do { \
|
||||
const struct nl_cb *_cb = (cb); \
|
||||
\
|
||||
if (_cb->type##_cb) { \
|
||||
if (_cb && _cb->type##_cb) { \
|
||||
/* the returned value here must be either a negative
|
||||
* netlink error number, or one of NL_SKIP, NL_STOP, NL_OK. */ \
|
||||
nmerr = _cb->type##_cb ((msg), _cb->type##_arg); \
|
||||
|
|
@ -1171,7 +1171,7 @@ continue_reading:
|
|||
}
|
||||
if (e->error) {
|
||||
/* Error message reported back from kernel. */
|
||||
if (cb->err_cb) {
|
||||
if (cb && cb->err_cb) {
|
||||
/* the returned value here must be either a negative
|
||||
* netlink error number, or one of NL_SKIP, NL_STOP, NL_OK. */
|
||||
nmerr = cb->err_cb (&nla, e,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue