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 74E87431FBF for ; Sun, 22 Nov 2009 18:47:26 -0800 (PST) X-Virus-Scanned: Debian amavisd-new at olra.theworths.org 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 sBBGF8vs6YUS for ; Sun, 22 Nov 2009 18:47:25 -0800 (PST) Received: from mail-bw0-f224.google.com (mail-bw0-f224.google.com [209.85.218.224]) by olra.theworths.org (Postfix) with ESMTP id 95837431FAE for ; Sun, 22 Nov 2009 18:47:25 -0800 (PST) Received: by bwz24 with SMTP id 24so3606156bwz.30 for ; Sun, 22 Nov 2009 18:47:24 -0800 (PST) MIME-Version: 1.0 Received: by 10.204.26.152 with SMTP id e24mr4236487bkc.119.1258944444721; Sun, 22 Nov 2009 18:47:24 -0800 (PST) In-Reply-To: <876392ge3i.fsf@yoom.home.cworth.org> References: <1258893156-25849-1-git-send-email-jan@ryngle.com> <876392ge3i.fsf@yoom.home.cworth.org> Date: Mon, 23 Nov 2009 03:47:24 +0100 Message-ID: From: Jan Janak To: Carl Worth Content-Type: text/plain; charset=UTF-8 Cc: notmuch@notmuchmail.org Subject: Re: [notmuch] [PATCH] notmuch-new: Eliminate gcc warning caused by ino_cmp. X-BeenThere: notmuch@notmuchmail.org X-Mailman-Version: 2.1.12 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: Mon, 23 Nov 2009 02:47:26 -0000 On Mon, Nov 23, 2009 at 3:38 AM, Carl Worth wrote: > On Sun, 22 Nov 2009 13:32:36 +0100, Jan Janak wrote: >> The function passed to scandir in the fourth argument takes two >> const void* arguments. To eliminate the gcc warning about incompatible >> types, we change ino_cmp to match this and then re-type the parameters >> in the body of ino_cmp. > > Actually, on my system at least, (Linux with glibc 2.10.1), our current > function matches the prototype. So applying your patch actually > *introduces* a warning where there was no warning before. > > What a nuisance... > > Any ideas for a good fix, anyone? OK, I have an older version of glibc. If the original code works with glibc 2.10 then just ignore the patch. I think testing for a particular version of glibc is not worth the effort (it's just a warning anyway). -- Jan