Merge tag 'io_uring-6.6-2023-09-08' of git://git.kernel.dk/linux
[platform/kernel/linux-rpi.git] / fs / lockd / mon.c
index 1d9488c..87a0f20 100644 (file)
@@ -276,6 +276,9 @@ static struct nsm_handle *nsm_create_handle(const struct sockaddr *sap,
 {
        struct nsm_handle *new;
 
+       if (!hostname)
+               return NULL;
+
        new = kzalloc(sizeof(*new) + hostname_len + 1, GFP_KERNEL);
        if (unlikely(new == NULL))
                return NULL;