diff options
Diffstat (limited to 'security/selinux/ss/mls.c')
-rw-r--r-- | security/selinux/ss/mls.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/security/selinux/ss/mls.c b/security/selinux/ss/mls.c index 2cca8e251624..531b08a2c6cd 100644 --- a/security/selinux/ss/mls.c +++ b/security/selinux/ss/mls.c @@ -641,10 +641,14 @@ int mls_export_cat(const struct context *context, int rc = -EPERM; if (!selinux_mls_enabled) { - *low = NULL; - *low_len = 0; - *high = NULL; - *high_len = 0; + if (low != NULL) { + *low = NULL; + *low_len = 0; + } + if (high != NULL) { + *high = NULL; + *high_len = 0; + } return 0; } |