diff options
Diffstat (limited to 'net/netlabel/netlabel_cipso_v4.c')
-rw-r--r-- | net/netlabel/netlabel_cipso_v4.c | 26 |
1 files changed, 15 insertions, 11 deletions
diff --git a/net/netlabel/netlabel_cipso_v4.c b/net/netlabel/netlabel_cipso_v4.c index fe9851fac85d..743b05734a49 100644 --- a/net/netlabel/netlabel_cipso_v4.c +++ b/net/netlabel/netlabel_cipso_v4.c | |||
@@ -407,12 +407,14 @@ static int netlbl_cipsov4_add(struct sk_buff *skb, struct genl_info *info) | |||
407 | 407 | ||
408 | audit_buf = netlbl_audit_start_common(AUDIT_MAC_CIPSOV4_ADD, | 408 | audit_buf = netlbl_audit_start_common(AUDIT_MAC_CIPSOV4_ADD, |
409 | &audit_info); | 409 | &audit_info); |
410 | audit_log_format(audit_buf, | 410 | if (audit_buf != NULL) { |
411 | " cipso_doi=%u cipso_type=%s res=%u", | 411 | audit_log_format(audit_buf, |
412 | doi, | 412 | " cipso_doi=%u cipso_type=%s res=%u", |
413 | type_str, | 413 | doi, |
414 | ret_val == 0 ? 1 : 0); | 414 | type_str, |
415 | audit_log_end(audit_buf); | 415 | ret_val == 0 ? 1 : 0); |
416 | audit_log_end(audit_buf); | ||
417 | } | ||
416 | 418 | ||
417 | return ret_val; | 419 | return ret_val; |
418 | } | 420 | } |
@@ -680,11 +682,13 @@ static int netlbl_cipsov4_remove(struct sk_buff *skb, struct genl_info *info) | |||
680 | 682 | ||
681 | audit_buf = netlbl_audit_start_common(AUDIT_MAC_CIPSOV4_DEL, | 683 | audit_buf = netlbl_audit_start_common(AUDIT_MAC_CIPSOV4_DEL, |
682 | &audit_info); | 684 | &audit_info); |
683 | audit_log_format(audit_buf, | 685 | if (audit_buf != NULL) { |
684 | " cipso_doi=%u res=%u", | 686 | audit_log_format(audit_buf, |
685 | doi, | 687 | " cipso_doi=%u res=%u", |
686 | ret_val == 0 ? 1 : 0); | 688 | doi, |
687 | audit_log_end(audit_buf); | 689 | ret_val == 0 ? 1 : 0); |
690 | audit_log_end(audit_buf); | ||
691 | } | ||
688 | 692 | ||
689 | return ret_val; | 693 | return ret_val; |
690 | } | 694 | } |