
/*
 * exists so that you can fork something with no limits
 */

#include<stdio.h>
#include<sys/types.h>
#include<sys/time.h>
#include<sys/resource.h>



main(argc, argv)
     int argc;
     char **argv;
{
    int res;
    static struct rlimit no_limit = { RLIM_INFINITY, RLIM_INFINITY };

    if (argc < 2) {
	fprintf (stderr, "usage: nolimit program [args ...]\n");
	exit(1);
    }
    
    for (res = 0; res < RLIM_NLIMITS; res++)
	setrlimit (res, &no_limit);
    execv (argv[1], argv + 1);
    perror ("nolimit: execv");
    exit (1);
}
