Return-Path: X-Original-To: notmuch@notmuchmail.org Delivered-To: notmuch@notmuchmail.org Received: from localhost (localhost [127.0.0.1]) by olra.theworths.org (Postfix) with ESMTP id 84898431FB6 for ; Sat, 3 Nov 2012 20:24:17 -0700 (PDT) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none] autolearn=disabled Received: from olra.theworths.org ([127.0.0.1]) by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id feFoUzfVAB27 for ; Sat, 3 Nov 2012 20:24:17 -0700 (PDT) X-Greylist: delayed 489 seconds by postgrey-1.32 at olra; Sat, 03 Nov 2012 20:24:16 PDT Received: from foo.net (70-36-235-136.dsl.static.sonic.net [70.36.235.136]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by olra.theworths.org (Postfix) with ESMTPS id F36CD431FAE for ; Sat, 3 Nov 2012 20:24:16 -0700 (PDT) Received: from foo.net (localhost [127.0.0.1]) by foo.net (8.14.5+Sun/8.14.5) with ESMTP id qA43GHpQ025708; Sat, 3 Nov 2012 20:16:17 -0700 (PDT) Received: (from blakej@localhost) by foo.net (8.14.5+Sun/8.14.5/Submit) id qA43GHDw025707; Sat, 3 Nov 2012 20:16:17 -0700 (PDT) From: Blake Jones To: notmuch@notmuchmail.org Subject: [PATCH 09/10] debugger.c: correct return type from getppid() (Solaris support) Date: Sat, 3 Nov 2012 20:16:01 -0700 Message-Id: <1351998962-25135-10-git-send-email-blakej@foo.net> X-Mailer: git-send-email 1.7.3.2 In-Reply-To: <1351998962-25135-1-git-send-email-blakej@foo.net> References: <1351998962-25135-1-git-send-email-blakej@foo.net> X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-2.0.2 (foo.net [127.0.0.1]); Sat, 03 Nov 2012 20:16:17 -0700 (PDT) X-Mailman-Approved-At: Sun, 04 Nov 2012 01:30:19 -0800 Cc: Blake Jones X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 Nov 2012 03:24:17 -0000 Cast the return value of getppid() to "int" from "pid_t" in debugger.c, since it is being passed to sprintf("%d"), which wants an "int" argument. On Solaris, "pid_t" is a "long" for 32-bit programs. --- debugger.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/debugger.c b/debugger.c index e8b9378..8ff13d6 100644 --- a/debugger.c +++ b/debugger.c @@ -36,7 +36,7 @@ debugger_is_active (void) if (RUNNING_ON_VALGRIND) return TRUE; - sprintf (buf, "/proc/%d/exe", getppid ()); + sprintf (buf, "/proc/%d/exe", (int) getppid ()); if (readlink (buf, buf, sizeof (buf)) != -1 && strncmp (basename (buf), "gdb", 3) == 0) { -- 1.7.9.2