All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Grzegorz Jaśkiewicz" <gryzman@gmail.com>
To: reiserfs-list@namesys.com
Subject: [PATCH] make fs/reiser4/search.c compile with gcc 4.0
Date: Wed, 22 Sep 2004 20:45:55 +0200	[thread overview]
Message-ID: <2f4958ff0409221145524aed7b@mail.gmail.com> (raw)

Here's full message, this is linux 2.6.9-rc2-mm1
 gcc -Wp,-MD,fs/reiser4/.search.o.d -nostdinc -iwithprefix include
-D__KERNEL__ -Iinclude  -Wall -Wstrict-prototypes -Wno-trigraphs
-fno-strict-aliasing -fno-common -O2 -fomit-frame-pointer
-Wdeclaration-after-statement -pipe -msoft-float
-mpreferred-stack-boundary=2 -fno-unit-at-a-time -march=pentium3
-Iinclude/asm-i386/mach-default -Wformat -Wundef -Wunused -Wcomment
-Wno-nested-externs -Wno-write-strings -Wno-sign-compare
-Wuninitialized   -DKBUILD_BASENAME=search -DKBUILD_MODNAME=reiser4 -c
-o fs/reiser4/.tmp_search.o fs/reiser4/search.c
fs/reiser4/search.c: In function 'cbk_node_lookup':
fs/reiser4/search.c:1111: error: invalid storage class for function 'key_is_ld'

gcc --version
gcc (GCC) 4.0.0 20040922 (experimental)
Copyright (C) 2004 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

I know gcc 4.0 is still in it's alphas.
Obvious solution is to move function declared in other function
up-wards. Since it's static anyway, it won't make any diffrence.
Please consider applying to repo.
Thanks.

-----

--- fs/reiser4/search.c    2004-09-22 20:38:04 +0200
+++ fs/reiser4/search.new.c        2004-09-22 20:37:26 +0200
@@ -1088,6 +1088,20 @@
 }
 #endif

+/* true if @key is left delimiting key of @node */
+static int key_is_ld(znode * node, const reiser4_key * key) {
+       int ld;
+
+        assert("nikita-1716", node != NULL);
+        assert("nikita-1758", key != NULL);
+
+        RLOCK_DK(znode_get_tree(node));
+        assert("nikita-1759", znode_contains_key(node, key));
+        ld = keyeq(znode_get_ld_key(node), key);
+        RUNLOCK_DK(znode_get_tree(node));
+        return ld;
+}
+
 /* Process one node during tree traversal.

    This is called by cbk_level_lookup(). */
@@ -1107,19 +1121,6 @@
        /* result */
        int result;

-       /* true if @key is left delimiting key of @node */
-       static int key_is_ld(znode * node, const reiser4_key * key) {
-               int ld;
-
-                assert("nikita-1716", node != NULL);
-                assert("nikita-1758", key != NULL);
-
-                RLOCK_DK(znode_get_tree(node));
-                assert("nikita-1759", znode_contains_key(node, key));
-                ld = keyeq(znode_get_ld_key(node), key);
-                RUNLOCK_DK(znode_get_tree(node));
-                return ld;
-       }
        assert("nikita-379", h != NULL);

        active = h->active_lh->node;


-- 
GJ

             reply	other threads:[~2004-09-22 18:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-22 18:45 Grzegorz Jaśkiewicz [this message]
2004-09-22 18:59 ` [PATCH] make fs/reiser4/search.c compile with gcc 4.0 Valdis.Kletnieks
2004-09-22 19:03   ` Grzegorz Jaśkiewicz
2004-09-22 19:09     ` Valdis.Kletnieks

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=2f4958ff0409221145524aed7b@mail.gmail.com \
    --to=gryzman@gmail.com \
    --cc=reiserfs-list@namesys.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.