]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
Add missing initialization in service cache in nscd
authorUlrich Drepper <drepper@gmail.com>
Mon, 15 Aug 2011 02:20:09 +0000 (22:20 -0400)
committerUlrich Drepper <drepper@gmail.com>
Mon, 15 Aug 2011 02:20:09 +0000 (22:20 -0400)
ChangeLog
nscd/servicescache.c

index 6d543f626317017df225c067ebf32f986ec5277b..eaa7b7e0d4af8cc72187c7c632a4c42ebc16aa1d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2011-08-14  Ulrich Drepper  <drepper@gmail.com>
+
+       * nscd/servicescache.c (cache_addserv): Make sure written is always
+       initialized.
+
 2011-08-13  Ulrich Drepper  <drepper@gmail.com>
 
        * elf/dl-open.c: Rename show_scope to _dl_schow_scope and export.
index ec5a367db83027b3f53bb0047f89cd9ebf8f7ac5..d3d5dce44ec878500206c39b31b66d2eda4bfc33 100644 (file)
@@ -102,7 +102,7 @@ cache_addserv (struct database_dyn *db, int fd, request_header *req,
        {
          /* We have no data.  This means we send the standard reply for this
             case.  */
-         total = sizeof (notfound);
+         written = total = sizeof (notfound);
 
          if (fd != -1)
            written = TEMP_FAILURE_RETRY (send (fd, &notfound, total,