memset(c, 0, sizeof(*c)); 
static int read_cons_helper(struct constraint_node **nodep, int ncons,                            int allowxtarget, void *fp){	struct constraint_node *c, *lc;	struct constraint_expr *e, *le;	__le32 buf[3];	u32 nexpr;	int rc, i, j, depth;	lc = NULL;	for (i = 0; i < ncons; i++) {		c = kmalloc(sizeof(*c), GFP_KERNEL);		if (!c)			return -ENOMEM;		memset(c, 0, sizeof(*c));		if (lc) {			lc->next = c;		} else {			*nodep = c;		}		rc = next_entry(buf, fp, (sizeof(u32) * 2));		if (rc < 0)			return rc;		c->permissions = le32_to_cpu(buf[0]);		nexpr = le32_to_cpu(buf[1]);		le = NULL;		depth = -1;		for (j = 0; j < nexpr; j++) {			e = kmalloc(sizeof(*e), GFP_KERNEL);			if (!e)				return -ENOMEM;			memset(e, 0, sizeof(*e));			if (le) {				le->next = e;			} else {				c->expr = e;			}			rc = next_entry(buf, fp, (sizeof(u32) * 3));			if (rc < 0)				return rc;			e->expr_type = le32_to_cpu(buf[0]);			e->attr = le32_to_cpu(buf[1]);			e->op = le32_to_cpu(buf[2]);			switch (e->expr_type) {			case CEXPR_NOT:				if (depth < 0)					return -EINVAL;				break;			case CEXPR_AND:			case CEXPR_OR:				if (depth < 1)					return -EINVAL;				depth--;				break;			case CEXPR_ATTR:				if (depth == (CEXPR_MAXDEPTH - 1))					return -EINVAL;				depth++;				break;			case CEXPR_NAMES:				if (!allowxtarget && (e->attr & CEXPR_XTARGET))					return -EINVAL;				if (depth == (CEXPR_MAXDEPTH - 1))					return -EINVAL;				depth++;				if (ebitmap_read(&e->names, fp))					return -EINVAL;				break;			default:				return -EINVAL;			}			le = e;		}		if (depth != 0)			return -EINVAL;		lc = c;	}	return 0;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/89d155ef62e5e0c10e4b37aaa5056f0beafe10e6/policydb.c/buggy/security/selinux/ss/policydb.c