Print this page
6659 nvlist_free(NULL) is a no-op

@@ -353,11 +353,10 @@
         /* push the bits out on the wire */
 
         status = stmf_ic_transmit(buf, size);
 
 done:
-        if (nvl)
                 nvlist_free(nvl);
 
         if (buf)
                 kmem_free(buf, size);
 

@@ -969,11 +968,10 @@
 
         default:
                 ASSERT(0);
         }
 
-        if (msg->icm_nvlist)
                 nvlist_free(msg->icm_nvlist);
 
         kmem_free(msg, sizeof (*msg));
 }
 

@@ -1174,11 +1172,10 @@
 
 done:
         if (!rc)
                 return (nvl);
 
-        if (nvl)
                 nvlist_free(nvl);
 
         return (NULL);
 }