]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
(__attribute__, ATTRIBUTE_UNUSED): Define.
authorJim Meyering <jim@meyering.net>
Sat, 9 Apr 2005 14:19:49 +0000 (14:19 +0000)
committerJim Meyering <jim@meyering.net>
Sat, 9 Apr 2005 14:19:49 +0000 (14:19 +0000)
Mark parameter `sp' with ATTRIBUTE_UNUSED.

lib/fts.c

index fe7159ebf0dd6b104df7ffb733461d21a6d83762..c4f704dcbacb0ea03555844260f1a43a3a9f1054 100644 (file)
--- a/lib/fts.c
+++ b/lib/fts.c
@@ -142,6 +142,16 @@ int rpl_lstat (const char *, struct stat *);
 # define __set_errno(Val) errno = (Val)
 #endif
 
+#ifndef __attribute__
+# if __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 8) || __STRICT_ANSI__
+#  define __attribute__(x) /* empty */
+# endif
+#endif
+
+#ifndef ATTRIBUTE_UNUSED
+# define ATTRIBUTE_UNUSED __attribute__ ((__unused__))
+#endif
+
 
 static FTSENT  *fts_alloc __P((FTS *, const char *, size_t)) internal_function;
 static FTSENT  *fts_build __P((FTS *, int)) internal_function;
@@ -746,10 +756,7 @@ name:              t = sp->fts_path + NAPPEND(p->fts_parent);
  */
 /* ARGSUSED */
 int
-fts_set(sp, p, instr)
-       FTS *sp;
-       FTSENT *p;
-       int instr;
+fts_set(FTS *sp ATTRIBUTE_UNUSED, FTSENT *p, int instr)
 {
        if (instr != 0 && instr != FTS_AGAIN && instr != FTS_FOLLOW &&
            instr != FTS_NOINSTR && instr != FTS_SKIP) {