[Libreoffice] [PATCH] Refactor to make cppcheck happy

Justin Malcolm malcolm.justin at gmail.com
Wed Sep 29 17:57:23 PDT 2010

Wow, cut me off!

Here is the warning:

(error) Common realloc mistake: "ptr" nulled but not freed upon failure

Unfortunately, the patch I sent was somehow incorrect.  I am really not sure
how I managed that as my local copy seems correct.  Anyway, thanks for not
letting me introduce a bug.

Attached is the corrected patch.

On 29 September 2010 13:32, Kohei Yoshida <kyoshida at novell.com> wrote:

> On Wed, 2010-09-29 at 21:02 +0100, Michael Meeks wrote:
> > > Attached is a small patch that does nothing except eliminate one
> > > cppcheck warning.  It is contributed under the LGPL3+.
> >
> >         What is the warning ? :-)
> I can give you that info as I was also curious about this:
> $ cppcheck soltools/javadep/javadep.c
> Checking soltools/javadep/javadep.c...
> [soltools/javadep/javadep.c:606]: (error) Common realloc mistake: "ptr"
> nulled but not freed upon failure
> Checking soltools/javadep/javadep.c: DEBUG...
> Checking soltools/javadep/javadep.c: OS2...
> Checking soltools/javadep/javadep.c: WNT...
> --
> Kohei Yoshida, LibreOffice hacker, Calc
> <kyoshida at novell.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20100929/dadf2996/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: javadep.diff
Type: text/x-patch
Size: 457 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/libreoffice/attachments/20100929/dadf2996/attachment-0001.bin>

More information about the LibreOffice mailing list