mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-05-25 22:19:17 +00:00
Check for setrlimit()
Originally committed as revision 21733 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
614d8911c6
commit
0104b608ca
2 changed files with 3 additions and 1 deletions
|
@ -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))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue