cladatum = kmalloc(sizeof(*cladatum), GFP_KERNEL); 
cladatum = kzalloc(sizeof(*cladatum), GFP_KERNEL); 
static int class_read(struct policydb *p, struct hashtab *h, void *fp){	char *key = NULL;	struct class_datum *cladatum;	__le32 buf[6];	u32 len, len2, ncons, nel;	int i, rc;	cladatum = kmalloc(sizeof(*cladatum), GFP_KERNEL);	if (!cladatum) {		rc = -ENOMEM;		goto out;	}	memset(cladatum, 0, sizeof(*cladatum));	rc = next_entry(buf, fp, sizeof(u32)*6);	if (rc < 0)		goto bad;	len = le32_to_cpu(buf[0]);	len2 = le32_to_cpu(buf[1]);	cladatum->value = le32_to_cpu(buf[2]);	rc = symtab_init(&cladatum->permissions, PERM_SYMTAB_SIZE);	if (rc)		goto bad;	cladatum->permissions.nprim = le32_to_cpu(buf[3]);	nel = le32_to_cpu(buf[4]);	ncons = le32_to_cpu(buf[5]);	key = kmalloc(len + 1,GFP_KERNEL);	if (!key) {		rc = -ENOMEM;		goto bad;	}	rc = next_entry(key, fp, len);	if (rc < 0)		goto bad;	key[len] = 0;	if (len2) {		cladatum->comkey = kmalloc(len2 + 1,GFP_KERNEL);		if (!cladatum->comkey) {			rc = -ENOMEM;			goto bad;		}		rc = next_entry(cladatum->comkey, fp, len2);		if (rc < 0)			goto bad;		cladatum->comkey[len2] = 0;		cladatum->comdatum = hashtab_search(p->p_commons.table,						    cladatum->comkey);		if (!cladatum->comdatum) {			printk(KERN_ERR "security:  unknown common %s\n",			       cladatum->comkey);			rc = -EINVAL;			goto bad;		}	}	for (i = 0; i < nel; i++) {		rc = perm_read(p, cladatum->permissions.table, fp);		if (rc)			goto bad;	}	rc = read_cons_helper(&cladatum->constraints, ncons, 0, fp);	if (rc)		goto bad;	if (p->policyvers >= POLICYDB_VERSION_VALIDATETRANS) {		/* grab the validatetrans rules */		rc = next_entry(buf, fp, sizeof(u32));		if (rc < 0)			goto bad;		ncons = le32_to_cpu(buf[0]);		rc = read_cons_helper(&cladatum->validatetrans, ncons, 1, fp);		if (rc)			goto bad;	}	rc = hashtab_insert(h, key, cladatum);	if (rc)		goto bad;	rc = 0;out:	return rc;bad:	class_destroy(key, cladatum, NULL);	goto out;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/89d155ef62e5e0c10e4b37aaa5056f0beafe10e6/policydb.c/buggy/security/selinux/ss/policydb.c