Re: [xml] Regarding Malloc Failure Handling
- From: Stefan Behnel <stefan_ml behnel de>
- To: ashwins huawei com
- Cc: xml gnome org, veillard redhat com
- Subject: Re: [xml] Regarding Malloc Failure Handling
- Date: Mon, 24 Mar 2008 09:56:50 +0100
Hi,
Ashwin wrote:
Recently we performed failure testing on libxml, that is we simulated malloc
failures to see how libxml behaved in that scenario. As a result of the
testing we found a number of memory leaks and some crashes.
There are other similar problems, so I was wondering if there is
an assumption that malloc failure will not occur since it is a rare
occurrence. Or does corrective action need to be taken wherever it occurs in
the failure path.
In almost all of the code, malloc failures are handled correctly as errors, so
if you find places where that's not the case, that should be considered a bug
IMHO.
Stefan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]