Removed redundant test against MAXDSIZ (the rlimit test is stronger).

This commit is contained in:
Bruce Evans 1997-08-26 00:02:24 +00:00
parent 25ec9b1615
commit 282ec22c77
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=28765
2 changed files with 2 additions and 8 deletions

View File

@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
* $Id: imgact_aout.c,v 1.33 1997/02/22 09:38:55 peter Exp $
* $Id: imgact_aout.c,v 1.34 1997/04/13 01:48:21 dyson Exp $
*/
#include "opt_rlimit.h"
@ -128,9 +128,6 @@ exec_aout_imgact(imgp)
if (/* text can't exceed maximum text size */
a_out->a_text > MAXTSIZ ||
/* data + bss can't exceed maximum data size */
a_out->a_data + bss_size > MAXDSIZ ||
/* data + bss can't exceed rlimit */
a_out->a_data + bss_size >
imgp->proc->p_rlimit[RLIMIT_DATA].rlim_cur)

View File

@ -6,7 +6,7 @@
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------
*
* $Id: imgact_gzip.c,v 1.28 1997/02/22 09:38:57 peter Exp $
* $Id: imgact_gzip.c,v 1.29 1997/04/13 01:48:22 dyson Exp $
*
* This module handles execution of a.out files which have been run through
* "gzip". This saves diskspace, but wastes cpu-cycles and VM.
@ -204,9 +204,6 @@ do_aout_hdr(struct imgact_gzip * gz)
if ( /* text can't exceed maximum text size */
gz->a_out.a_text > MAXTSIZ ||
/* data + bss can't exceed maximum data size */
gz->a_out.a_data + gz->bss_size > MAXDSIZ ||
/* data + bss can't exceed rlimit */
gz->a_out.a_data + gz->bss_size >
gz->ip->proc->p_rlimit[RLIMIT_DATA].rlim_cur) {