mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-01 07:12:51 +08:00
Check for setrlimit()
Originally committed as revision 21733 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@ -264,7 +264,7 @@ int opt_loglevel(const char *opt, const char *arg)
|
||||
|
||||
int opt_timelimit(const char *opt, const char *arg)
|
||||
{
|
||||
#if HAVE_SYS_RESOURCE_H
|
||||
#if HAVE_SETRLIMIT
|
||||
int lim = parse_number_or_die(opt, arg, OPT_INT64, 0, INT_MAX);
|
||||
struct rlimit rl = { lim, lim + 1 };
|
||||
if (setrlimit(RLIMIT_CPU, &rl))
|
||||
|
Reference in New Issue
Block a user