diff options
| author | James Morris <jmorris@namei.org> | 2011-05-24 22:55:24 +1000 | 
|---|---|---|
| committer | James Morris <jmorris@namei.org> | 2011-05-24 22:55:24 +1000 | 
| commit | 434d42cfd05a7cc452457a81d2029540cba12150 (patch) | |
| tree | 3a6b9b7f9ff2e1b7409dd66c15242b2a75aa4422 /fs/binfmt_flat.c | |
| parent | d762f4383100c2a87b1a3f2d678cd3b5425655b4 (diff) | |
| parent | 12a5a2621b1ee14d32beca35304d7c6076a58815 (diff) | |
| download | olio-linux-3.10-434d42cfd05a7cc452457a81d2029540cba12150.tar.xz olio-linux-3.10-434d42cfd05a7cc452457a81d2029540cba12150.zip  | |
Merge branch 'next' into for-linus
Diffstat (limited to 'fs/binfmt_flat.c')
| -rw-r--r-- | fs/binfmt_flat.c | 8 | 
1 files changed, 8 insertions, 0 deletions
diff --git a/fs/binfmt_flat.c b/fs/binfmt_flat.c index 397d3057d33..1bffbe0ed77 100644 --- a/fs/binfmt_flat.c +++ b/fs/binfmt_flat.c @@ -820,6 +820,8 @@ static int load_flat_shared_library(int id, struct lib_info *libs)  	int res;  	char buf[16]; +	memset(&bprm, 0, sizeof(bprm)); +  	/* Create the file name */  	sprintf(buf, "/lib/lib%d.so", id); @@ -835,6 +837,12 @@ static int load_flat_shared_library(int id, struct lib_info *libs)  	if (!bprm.cred)  		goto out; +	/* We don't really care about recalculating credentials at this point +	 * as we're past the point of no return and are dealing with shared +	 * libraries. +	 */ +	bprm.cred_prepared = 1; +  	res = prepare_binprm(&bprm);  	if (!IS_ERR_VALUE(res))  |