From patchwork Thu May 1 20:01:30 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Andreas Schwab X-Patchwork-Id: 781 Return-Path: X-Original-To: siddhesh@wilcox.dreamhost.com Delivered-To: siddhesh@wilcox.dreamhost.com Received: from homiemail-mx20.g.dreamhost.com (mx2.sub5.homie.mail.dreamhost.com [208.113.200.128]) by wilcox.dreamhost.com (Postfix) with ESMTP id CA8B2360078 for ; Thu, 1 May 2014 13:01:39 -0700 (PDT) Received: by homiemail-mx20.g.dreamhost.com (Postfix, from userid 14307373) id 8066341554806; Thu, 1 May 2014 13:01:39 -0700 (PDT) X-Original-To: glibc@patchwork.siddhesh.in Delivered-To: x14307373@homiemail-mx20.g.dreamhost.com Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by homiemail-mx20.g.dreamhost.com (Postfix) with ESMTPS id 5E05841554864 for ; Thu, 1 May 2014 13:01:39 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:references:date:in-reply-to :message-id:mime-version:content-type:content-transfer-encoding; q=dns; s=default; b=Pe8D2goO6I3lFSnANODhzFhr9Ar0s5DGIoMmWQn4day hhdtGNAKvYjaPBUHViHF9xVQRIdOC6uLRqEHZCwVyPGP04dUvW2Oy4Ri3meDUk8D CnHFEQJApzOcOVCyeAZT3zbFW72fpcgHyMBqJbwFusPafkzmt5x9N8jl1W1h27ow = DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id :list-unsubscribe:list-subscribe:list-archive:list-post :list-help:sender:from:to:cc:subject:references:date:in-reply-to :message-id:mime-version:content-type:content-transfer-encoding; s=default; bh=z+DPq3oEd8+fJSPpwhhlIham4s4=; b=bNIAg0ZTEfbRVySiN 1T57ntFMeM4zbV5rk0lYix0DxHIDpbsp2OpIMrCPnOEuMWj1/EQVWxUo042zVr4W Gn7UV85pnwUtaRxxILoRm9hgBlLyGH8nWlbR3QyZw+xCMiQKoxQmHeXjQvSyu5na Ym6hZNt/xRNQJS8+HS6IW3mtb4= Received: (qmail 12335 invoked by alias); 1 May 2014 20:01:37 -0000 Mailing-List: contact libc-alpha-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: libc-alpha-owner@sourceware.org Delivered-To: mailing list libc-alpha@sourceware.org Received: (qmail 12321 invoked by uid 89); 1 May 2014 20:01:37 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-1.6 required=5.0 tests=AWL, BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.2 X-HELO: mail-out.m-online.net X-Auth-Info: H71rTp2/qtOxqMiEDaxSLGRC9n1Ejxrn98wHK/2ncMU= From: Andreas Schwab To: Siddhesh Poyarekar Cc: Mike Frysinger , libc-alpha@sourceware.org, Roland McGrath Subject: Re: [PATCH 2/2] Initialize all of datahead structure in nscd [BZ #16791] References: <20140401164104.GH16484@spoyarek.pnq.redhat.com> <24966439.irburZmzZi@vapier> <20140402094011.GD23931@spoyarek.pnq.redhat.com> <2541735.7QtA0LDnTJ@vapier> <20140403150921.GA5063@spoyarek.pnq.redhat.com> X-Yow: They don't hire PERSONAL PINHEADS, Mr. Toad! Date: Thu, 01 May 2014 22:01:30 +0200 In-Reply-To: <20140403150921.GA5063@spoyarek.pnq.redhat.com> (Siddhesh Poyarekar's message of "Thu, 3 Apr 2014 20:39:21 +0530") Message-ID: <87y4yluv39.fsf@igel.home> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 X-DH-Original-To: glibc@patchwork.siddhesh.in Siddhesh Poyarekar writes: > diff --git a/nscd/nscd-client.h b/nscd/nscd-client.h > index c069bf6..ee16df6 100644 > --- a/nscd/nscd-client.h > +++ b/nscd/nscd-client.h > @@ -240,12 +240,17 @@ static inline time_t > datahead_init_common (struct datahead *head, nscd_ssize_t allocsize, > nscd_ssize_t recsize, uint32_t ttl) > { > + /* Initialize so that we don't write out junk in uninitialized data to the > + cache. */ > + memset (head, 0, sizeof (*head)); nscd-client.h: In function ‘datahead_init_common’: nscd-client.h:245:3: warning: implicit declaration of function ‘memset’ [-Wimplicit-function-declaration] memset (head, 0, sizeof (*head)); ^ nscd-client.h:245:3: warning: incompatible implicit declaration of built-in function ‘memset’ [enabled by default] Andreas. * nscd/nscd-client.h: Include . diff --git a/nscd/nscd-client.h b/nscd/nscd-client.h index ee16df6..cabba49 100644 --- a/nscd/nscd-client.h +++ b/nscd/nscd-client.h @@ -24,6 +24,7 @@ #include #include +#include #include #include #include