From patchwork Tue May 13 15:24:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Schwab X-Patchwork-Id: 886 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 5A42436007B for ; Tue, 13 May 2014 08:24:17 -0700 (PDT) Received: by homiemail-mx20.g.dreamhost.com (Postfix, from userid 14307373) id 03BEA41B33C26; Tue, 13 May 2014 08:24:16 -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 BA1AE41B33C1D for ; Tue, 13 May 2014 08:24:16 -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:subject:date:message-id:mime-version :content-type; q=dns; s=default; b=mUay9t5B0IqFpDFKre3OJP6XWFVST HWClTwRpUHsQuLgMMXbopS9oxpeTMAKrEi+OvvBRKuaRJvvvScsLADNFK0e6pyr8 dtDAMCNeo1ehFxCoXIQYKR+DkfdWGLHKP9BLTHvAN8qPdGjBHCIShuPd1qNRfkkl ajpg3AMM0RLMP8= 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:subject:date:message-id:mime-version :content-type; s=default; bh=HI/+4lKJLWLWkdB7SRVFrN9iGnQ=; b=HOf gFrp63t3/W0qkjtb9snWrNN74LPlk2rseVnPawJ88jOPQZgn8coU/nLEYeCDuSGG a2omlDIso770wr7F7tAJ6ElLHcSddL6HsTXcNWXvxUmXp6ICnTIP9nnMGaXsQBJu MdqJj99NKMU1uEMCazHzQSZv4NEEOL37zqVCQvog= Received: (qmail 11161 invoked by alias); 13 May 2014 15:24:06 -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 11000 invoked by uid 89); 13 May 2014 15:24:05 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-3.2 required=5.0 tests=AWL, BAYES_00, RP_MATCHES_RCVD autolearn=ham version=3.3.2 X-HELO: mx2.suse.de From: Andreas Schwab To: libc-alpha@sourceware.org Subject: [PATCH] Fix macro warning on HAVE_PT_CHOWN X-Yow: Everybody gets free BORSCHT! Date: Tue, 13 May 2014 17:24:01 +0200 Message-ID: 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 Tested with --enable-pt-chown=[yes|no]. Andreas. * config.h.in (HAVE_PT_CHOWN): Define as 0. * sysdeps/unix/grantpt.c (grantpt): Check HAVE_PT_CHOWN for value, not definedness. --- config.h.in | 2 +- sysdeps/unix/grantpt.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/config.h.in b/config.h.in index b6e3623..a9ff1e3 100644 --- a/config.h.in +++ b/config.h.in @@ -251,7 +251,7 @@ #undef HAVE_ARM_PCS_VFP /* The pt_chown binary is being built and used by grantpt. */ -#undef HAVE_PT_CHOWN +#define HAVE_PT_CHOWN 0 /* ports/sysdeps/mips/configure.in */ /* Define if using the IEEE 754-2008 NaN encoding on the MIPS target. */ diff --git a/sysdeps/unix/grantpt.c b/sysdeps/unix/grantpt.c index 410dc50..2cb277c 100644 --- a/sysdeps/unix/grantpt.c +++ b/sysdeps/unix/grantpt.c @@ -176,7 +176,7 @@ grantpt (int fd) /* We have to use the helper program if it is available. */ helper:; -#ifdef HAVE_PT_CHOWN +#if HAVE_PT_CHOWN pid_t pid = __fork (); if (pid == -1) goto cleanup;