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

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/dev/sdev_ncache.c
          +++ new/usr/src/uts/common/fs/dev/sdev_ncache.c
↓ open down ↓ 333 lines elided ↑ open up ↑
 334  334                              nvf_cache_name(fd), rval);
 335  335                          goto err;
 336  336                  }
 337  337                  nvlist_free(sub_nvl);
 338  338          }
 339  339  
 340  340          *ret_nvl = nvl;
 341  341          return (DDI_SUCCESS);
 342  342  
 343  343  err:
 344      -        if (sub_nvl)
 345      -                nvlist_free(sub_nvl);
      344 +        nvlist_free(sub_nvl);
 346  345          nvlist_free(nvl);
 347  346          *ret_nvl = NULL;
 348  347          return (DDI_FAILURE);
 349  348  }
 350  349  
 351  350  /*
 352  351   * Run through the data read from the backing cache store
 353  352   * to establish the initial state of the neg. cache.
 354  353   */
 355  354  static void
↓ open down ↓ 558 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX