[MPlayer-dev-eng] [RFC] rlimits support

Dave Yeo dave.r.yeo at gmail.com
Mon Oct 11 07:34:07 CEST 2010


On 10/09/10 07:14 am, Reimar Döffinger wrote:
> On Sat, Oct 09, 2010 at 09:56:03AM -0400, compn wrote:
>> >  On Sat, 9 Oct 2010 15:03:53 +0200, Reimar Döffinger wrote:
>>> >  >this is an unfinished patch to add support for rlimits.
>>> >  >The main point of it would be to limit RLIMIT_DATA to something
>>> >  >"reasonable" like e.g. 512 MB by default, which for most users
>>> >  >would guarantee that MPlayer never causes an unusable system
>>> >  >due to a memleak and excessive swapping caused by that.
>>> >  >This should also make it possible to test in a semi-automated
>>> >  >way that MPlayer can handle out-of-memory conditions where
>>> >  >NULL is returned by malloc.
>>> >  >It lacks at the very least: configure check, command-line option,
>>> >  >documentation.
>> >
>> >  any idea which OS supports rlimit ? e.g. mplayer builds on osx,
>> >  cygwin/mingw, os/2, bsd etc.
> man page says: CONFORMING TO SVr4, 4.3BSD, POSIX.1-2001.
> OS/2 doesn't have it and probably does not have anything comparable,

Actually OS/2 does have it (I haven't tested it) though the default 
limit should be smaller, perhaps 256MBs due to the default 512MB per 
process limit.
Dave


More information about the MPlayer-dev-eng mailing list