From 6cb7a76f8e927844be91e30f172e85f2735b848a Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Wed, 28 Jul 2004 00:31:14 +0000 Subject: [PATCH] Remove now-inaccurate comment about the files you need to include first. You don't need to include any files other than the usual config.h. Include and if available, for uintmax_t. Remove 'struct stat;' not needed since we know sys/stat.h has been included by dev-ino.h. (struct cycle_check_state): Change chdir_counter to uintmax_t, not size_t, since it isn't limited by object sizes. Change magic from long unsigned int to int; that's good enough for our use. --- lib/cycle-check.h | 25 ++++++++----------------- 1 file changed, 8 insertions(+), 17 deletions(-) diff --git a/lib/cycle-check.h b/lib/cycle-check.h index 76cf104ab3..8c50c30eae 100644 --- a/lib/cycle-check.h +++ b/lib/cycle-check.h @@ -1,29 +1,20 @@ #ifndef CYCLE_CHECK_H # define CYCLE_CHECK_H 1 -/* Before including this file, you need something like the following: - - #if HAVE_CONFIG_H - # include - #endif - - #include - #include - - #include - - so that the proper identifiers are all declared. */ - +# if HAVE_INTTYPES_H +# include +# endif +# if HAVE_STDINT_H +# include +# endif # include # include "dev-ino.h" -struct stat; - struct cycle_check_state { struct dev_ino dev_ino; - size_t chdir_counter; - long unsigned int magic; + uintmax_t chdir_counter; + int magic; }; void cycle_check_init (struct cycle_check_state *state); -- 2.47.2