tcon = kmalloc(size+1, GFP_KERNEL); 
tcon = kzalloc(size+1, GFP_KERNEL); 
static ssize_t sel_write_relabel(struct file * file, char *buf, size_t size){	char *scon, *tcon;	u32 ssid, tsid, newsid;	u16 tclass;	ssize_t length;	char *newcon;	u32 len;	length = task_has_security(current, SECURITY__COMPUTE_RELABEL);	if (length)		return length;	length = -ENOMEM;	scon = kmalloc(size+1, GFP_KERNEL);	if (!scon)		return length;	memset(scon, 0, size+1);	tcon = kmalloc(size+1, GFP_KERNEL);	if (!tcon)		goto out;	memset(tcon, 0, size+1);	length = -EINVAL;	if (sscanf(buf, "%s %s %hu", scon, tcon, &tclass) != 3)		goto out2;	length = security_context_to_sid(scon, strlen(scon)+1, &ssid);	if (length < 0)		goto out2;	length = security_context_to_sid(tcon, strlen(tcon)+1, &tsid);	if (length < 0)		goto out2;	length = security_change_sid(ssid, tsid, tclass, &newsid);	if (length < 0)		goto out2;	length = security_sid_to_context(newsid, &newcon, &len);	if (length < 0)		goto out2;	if (len > SIMPLE_TRANSACTION_LIMIT) {		length = -ERANGE;		goto out3;	}	memcpy(buf, newcon, len);	length = len;out3:	kfree(newcon);out2:	kfree(tcon);out:	kfree(scon);	return length;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/89d155ef62e5e0c10e4b37aaa5056f0beafe10e6/selinuxfs.c/buggy/security/selinux/selinuxfs.c