X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Fmountlist.c;h=50e90eed473253e4be76068808ba7161bbd67c67;hb=cdfe647f8d29540cdfe90cef0fa568c5d2fd4481;hp=119cdf00ad8ad12eb25b1f5a1e5de998d482aa5c;hpb=e97e3a48d3a23446cf334e288aa6f138a6f9bae5;p=gnulib.git diff --git a/lib/mountlist.c b/lib/mountlist.c index 119cdf00a..50e90eed4 100644 --- a/lib/mountlist.c +++ b/lib/mountlist.c @@ -1,6 +1,6 @@ /* mountlist.c -- return a list of mounted file systems - Copyright (C) 1991, 1992, 1997-2008 Free Software Foundation, Inc. + Copyright (C) 1991, 1992, 1997-2009 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -23,6 +23,7 @@ #include #include #include +#include #include "xalloc.h" @@ -133,10 +134,6 @@ # include "unlocked-io.h" #endif -#ifndef SIZE_MAX -# define SIZE_MAX ((size_t) -1) -#endif - /* The results of open() in this file are not used with fchdir, therefore save some unnecessary work in fchdir.c. */ #undef open @@ -297,17 +294,10 @@ fstype_to_string (int t) #if defined MOUNTED_GETMNTENT1 || defined MOUNTED_GETMNTENT2 -#undef UNUSED_PARAM -#ifdef __linux__ -# define UNUSED_PARAM _UNUSED_PARAMETER_ -#else -# define UNUSED_PARAM -#endif - /* Return the device number from MOUNT_OPTIONS, if possible. Otherwise return (dev_t) -1. */ static dev_t -dev_from_mount_options (char const *mount_options UNUSED_PARAM) +dev_from_mount_options (char const *mount_options) { /* GNU/Linux allows file system implementations to define their own meaning for "dev=" mount options, so don't trust the meaning @@ -332,30 +322,24 @@ dev_from_mount_options (char const *mount_options UNUSED_PARAM) } # endif - + (void) mount_options; return -1; } #endif -#undef UNUSED_PARAM -#ifdef GETFSTYP -# define UNUSED_PARAM -#else -# define UNUSED_PARAM _UNUSED_PARAMETER_ -#endif - /* Return a list of the currently mounted file systems, or NULL on error. Add each entry to the tail of the list so that they stay in order. If NEED_FS_TYPE is true, ensure that the file system type fields in the returned list are valid. Otherwise, they might not be. */ struct mount_entry * -read_file_system_list (bool need_fs_type UNUSED_PARAM) +read_file_system_list (bool need_fs_type) { struct mount_entry *mount_list; struct mount_entry *me; struct mount_entry **mtail = &mount_list; + (void) need_fs_type; #ifdef MOUNTED_LISTMNTENT {