if (buf) kfree(buf); 
kfree(buf); 
static int svc_export_parse(struct cache_detail *cd, char *mesg, int mlen){	/* client path expiry [flags anonuid anongid fsid] */	char *buf;	int len;	int err;	struct auth_domain *dom = NULL;	struct nameidata nd;	struct svc_export exp, *expp;	int an_int;	nd.dentry = NULL;	if (mesg[mlen-1] != '\n')		return -EINVAL;	mesg[mlen-1] = 0;	buf = kmalloc(PAGE_SIZE, GFP_KERNEL);	err = -ENOMEM;	if (!buf) goto out;	/* client */	len = qword_get(&mesg, buf, PAGE_SIZE);	err = -EINVAL;	if (len <= 0) goto out;	err = -ENOENT;	dom = auth_domain_find(buf);	if (!dom)		goto out;	/* path */	err = -EINVAL;	if ((len=qword_get(&mesg, buf, PAGE_SIZE)) <= 0)		goto out;	err = path_lookup(buf, 0, &nd);	if (err) goto out;	exp.h.flags = 0;	exp.ex_client = dom;	exp.ex_mnt = nd.mnt;	exp.ex_dentry = nd.dentry;	/* expiry */	err = -EINVAL;	exp.h.expiry_time = get_expiry(&mesg);	if (exp.h.expiry_time == 0)		goto out;	/* flags */	err = get_int(&mesg, &an_int);	if (err == -ENOENT)		set_bit(CACHE_NEGATIVE, &exp.h.flags);	else {		if (err || an_int < 0) goto out;			exp.ex_flags= an_int;			/* anon uid */		err = get_int(&mesg, &an_int);		if (err) goto out;		exp.ex_anon_uid= an_int;		/* anon gid */		err = get_int(&mesg, &an_int);		if (err) goto out;		exp.ex_anon_gid= an_int;		/* fsid */		err = get_int(&mesg, &an_int);		if (err) goto out;		exp.ex_fsid = an_int;		err = check_export(nd.dentry->d_inode, exp.ex_flags);		if (err) goto out;	}	expp = svc_export_lookup(&exp, 1);	if (expp)		exp_put(expp);	err = 0;	cache_flush(); out:	if (nd.dentry)		path_release(&nd);	if (dom)		auth_domain_put(dom);	if (buf)		kfree(buf);	return err;}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/f99d49adf527fa6f7a9c42257fa76bca6b8df1e3/export.c/buggy/fs/nfsd/export.c