patch-2.3.5 linux/fs/binfmt_misc.c

Next file: linux/fs/binfmt_script.c
Previous file: linux/fs/binfmt_java.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_misc.c linux/fs/binfmt_misc.c
@@ -210,13 +210,12 @@
 
 	/* Build args for interpreter */
 	remove_arg_zero(bprm);
-	bprm->p = copy_strings(1, &bprm->filename, bprm->page, bprm->p, 2);
+	retval = copy_strings_kernel(1, &bprm->filename, bprm);
+	if (retval < 0) goto _ret; 
 	bprm->argc++;
-	bprm->p = copy_strings(1, &iname_addr, bprm->page, bprm->p, 2);
+	retval = copy_strings_kernel(1, &iname_addr, bprm);
+	if (retval < 0) goto _ret; 
 	bprm->argc++;
-	retval = -E2BIG;
-	if (!bprm->p)
-		goto _ret;
 	bprm->filename = iname;	/* for binfmt_script */
 
 	dentry = open_namei(iname, 0, 0);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)