[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-wget] [PATCH] Replaced-xfree_null-by-xfree-and-nullify-argument-aft

From: Tim Rühsen
Subject: [Bug-wget] [PATCH] Replaced-xfree_null-by-xfree-and-nullify-argument-aftfer-freeing
Date: Sat, 29 Nov 2014 18:02:39 +0100
User-agent: KMail/4.14.2 (Linux/3.16.0-4-amd64; KDE/4.14.2; x86_64; ; )

This patch removes xfree_null() and replaces it by xfree().
xfree() automatically nullifies the argument after freeing to reduce dangling
pointer problems like double frees.

I also cleaned up code like
        if (p)
          xfree (p);

        p = NULL;

Both cases reduce to a call to xfree(p).

check and distcheck tested, also valgrind tested.

Please review and comment.


Attachment: 0001-Replaced-xfree_null-by-xfree-and-nullify-argument-af.patch
Description: Text Data

Attachment: signature.asc
Description: This is a digitally signed message part.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]