Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-7077

Pointer 'hash' returned from call to function 'cfs_hash_getref' may be NULL and will be dereferenced.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • Lustre 2.8.0
    • None
    • 3
    • 9223372036854775807

      lustre/obdclass/genops.c:944

      hash = cfs_hash_getref(exp->exp_obd->obd_gen_hash);
      cfs_hash_del(hash, &ted->ted_lcd->lcd_generation,
      	     &exp->exp_gen_hash);
      cfs_hash_putref(hash);
      
      struct cfs_hash *cfs_hash_getref(struct cfs_hash *hs)
      {
      	if (atomic_inc_not_zero(&hs->hs_refcount))
      		return hs;
      	return NULL;
      }
      

            bogl Bob Glossman (Inactive)
            dmiter Dmitry Eremin (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: