From owner-freebsd-current@FreeBSD.ORG Sun Apr 21 22:09:17 2013 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 47147D0B for ; Sun, 21 Apr 2013 22:09:17 +0000 (UTC) (envelope-from edschouten@gmail.com) Received: from mail-vc0-f173.google.com (mail-vc0-f173.google.com [209.85.220.173]) by mx1.freebsd.org (Postfix) with ESMTP id 0C6E613CE for ; Sun, 21 Apr 2013 22:09:16 +0000 (UTC) Received: by mail-vc0-f173.google.com with SMTP id gf12so5530926vcb.18 for ; Sun, 21 Apr 2013 15:09:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:x-received:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type; bh=gkHVt2EM5pGQVJeKBhqc7PRRqU97y6NsT7mhzaXCPuw=; b=I9hxEvsCjMZpNfKq//m41kq+gFeLTVGujw7RDq5+pzro70yJu6F8jTIOwEjk+wqVMF UxI/ZqHcOJ7PRube2mMkJp5ss78iyW21rstRjufxEkp/DBSEugHnN4hk7PZVITOm5+nR JtJe1y5hhJDwInYcpoHknhz5pqrPVEqhiaN0ByvtD+psE1YyyFiBmNhL1ElnrV2Zyl6D qNYWkLU5+UVfVVgHC9tCFCBTTVUU77rbQk2KVG6AQN2KaJs0f18jWN2t+y+sDvGL0/+l Nf0vgg9ZsDUu5uM6RSsZRNtYlwDrd9KUOJ8gTYz9wmcvsmu2y7GuxzLzmIMpFq/+6WJ6 Shqw== MIME-Version: 1.0 X-Received: by 10.220.147.79 with SMTP id k15mr3289624vcv.38.1366582150532; Sun, 21 Apr 2013 15:09:10 -0700 (PDT) Sender: edschouten@gmail.com Received: by 10.220.102.6 with HTTP; Sun, 21 Apr 2013 15:09:10 -0700 (PDT) In-Reply-To: <1366574922.38339.59.camel@thor.walstatt.dyndns.org> References: <1366574922.38339.59.camel@thor.walstatt.dyndns.org> Date: Mon, 22 Apr 2013 00:09:10 +0200 X-Google-Sender-Auth: w7jLp5dJHbYX_0WPb3WRW-hxWxo Message-ID: Subject: Re: CURRENT: /usr/src/sbin/newfs_nandfs/newfs_nandfs.c:89:18: error: no previous extern declaration for non-static variable From: Ed Schouten To: "O. Hartmann" Content-Type: text/plain; charset=UTF-8 Cc: FreeBSD Current X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 21 Apr 2013 22:09:17 -0000 Hi, 2013/4/21 O. Hartmann : > /usr/src/sbin/newfs_nandfs/newfs_nandfs.c:83:18: error: no previous > extern declaration for non-static variable > 'user_files' [-Werror,-Wmissing-variable-declarations] > struct file_info user_files[] = > ^ The following patch should fix this: http://80386.nl/pub/nandfs-warns-6.txt As of a couple of days ago, WARNS=6 requires that global variables either have an external declaration or are marked static. As newfs_nandfs only consists of a single C file, we can easily mark these variables static. In this specific case it allowed the compiler to find another peculiarity in the code, namely that the seg_segsum_size variable is unused. I'll commit this patch after I've done some testing. Thanks, -- Ed Schouten