Skip to content

Commit

Permalink
Fix memory leak when batch-reading large NIS password maps.
Browse files Browse the repository at this point in the history
Not the whole was traversed in the function to free all buffers.
BZ #10203
  • Loading branch information
Joe Landers authored and Ulrich Drepper committed Jun 16, 2009
1 parent 4155d92 commit 233a182
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
5 changes: 5 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
2009-06-15 Ulrich Drepper <drepper@redhat.com>

[BZ #10203]
* nis/nss_nis/nis-pwd.c (internal_nis_endpwent): Free all buffers,
not just the currently used one and those which follow.
Patch by Joe Landers <jlanders@vmware.com>.

[BZ #10196]
* libio/tst-fgetwc.c (do_test): Use de_DE.UTF-8 as locale name.
Patch by Bruce Dubbs <bdubbs@linuxfromscratch.org>.
Expand Down
4 changes: 2 additions & 2 deletions nis/nss_nis/nis-pwd.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* Copyright (C) 1996-1998,2001,2002,2003,2006 Free Software Foundation, Inc.
/* Copyright (C) 1996-1998,2001-2003,2006,2009 Free Software Foundation, Inc.
This file is part of the GNU C Library.
Contributed by Thorsten Kukuk <kukuk@vt.uni-paderborn.de>, 1996.
Expand Down Expand Up @@ -116,7 +116,7 @@ internal_nis_endpwent (void)
oldkeylen = 0;
}

struct response_t *curr = intern.next;
struct response_t *curr = intern.start;

while (curr != NULL)
{
Expand Down

0 comments on commit 233a182

Please sign in to comment.