No functional change, since free doesn't change the value of the pointer passed to it, but it makes this code less confusing.
Signed-off-by: Matt Turner <[email protected]> --- Alan, I saw this when looking through your parfait results. It looks like RecordFindContextOnAllContexts's argument should be marked const also. record/record.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/record/record.c b/record/record.c index 46231c9..bfc95bb 100644 --- a/record/record.c +++ b/record/record.c @@ -2522,8 +2522,6 @@ RecordDeleteContext(pointer value, XID id) } } - free(pContext); - /* remove context from AllContexts list */ if (-1 != (i = RecordFindContextOnAllContexts(pContext))) @@ -2535,6 +2533,8 @@ RecordDeleteContext(pointer value, XID id) ppAllContexts = NULL; } } + free(pContext); + return Success; } /* RecordDeleteContext */ -- 1.6.4.4 _______________________________________________ [email protected]: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel
