On Tue, 2012-02-28 at 14:48 +0100, Lubos Lunak wrote:
> - with today's systems (overcommitting, etc.) it is rather pointless to guard 
> against allocation failures

Another scenario of possibly more usefulness than actually "running out
of memory" is being directed to allocate a lunatic string size by some
busted document during import which is physically impossible to allocate
on a given architecture e.g. a broken .doc or whatever which claims to
have strings of SAL_MAX_SIZE * sal_Unicodes. Those would currently throw
std::bad_alloc without going anywhere near actually attempting to
allocate memory.

>  Does somebody see a good reason not to just remove it?

Mine's a somewhat contrived scenario, probably better to use custom foo
in places like the filters where the whole import can be abandoned on
epic failure.

C.

_______________________________________________
LibreOffice mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to