]> sourceware.org Git - lvm2.git/commitdiff
cleanup: drop unneeded included header files
authorZdenek Kabelac <zkabelac@redhat.com>
Thu, 16 Aug 2012 17:24:09 +0000 (19:24 +0200)
committerZdenek Kabelac <zkabelac@redhat.com>
Thu, 23 Aug 2012 12:37:20 +0000 (14:37 +0200)
This headers were not resolving anything used for compiled .c files.
Remove unused util.c file.

47 files changed:
daemons/clvmd/clvmd-command.c
daemons/dmeventd/dmeventd.c
daemons/dmeventd/plugins/lvm2/dmeventd_lvm.c
daemons/dmeventd/plugins/snapshot/dmeventd_snapshot.c
daemons/dmeventd/plugins/thin/dmeventd_thin.c
daemons/lvmetad/lvmetad-core.c
lib/Makefile.in
lib/activate/dev_manager.c
lib/cache/lvmetad.c
lib/config/config.c
lib/device/dev-swap.c
lib/error/errseg.c
lib/filters/filter-md.c
lib/filters/filter-sysfs.c
lib/format1/import-export.c
lib/format_pool/import_export.c
lib/format_pool/pool_label.c
lib/format_text/archive.c
lib/format_text/archiver.c
lib/format_text/format-text.c
lib/format_text/import.c
lib/format_text/text_label.c
lib/freeseg/freeseg.c
lib/log/log.c
lib/metadata/merge.c
lib/metadata/metadata.c
lib/metadata/mirror.c
lib/metadata/pv_manip.c
lib/metadata/pv_map.c
lib/metadata/raid_manip.c
lib/mirror/mirrored.c
lib/misc/lvm-file.c
lib/misc/lvm-globals.c
lib/misc/sharedlib.c
lib/misc/util.c [deleted file]
lib/replicator/replicator.c
lib/report/report.c
lib/thin/thin.c
lib/unknown/unknown.c
lib/zero/zero.c
libdm/libdm-deptree.c
tools/dmsetup.c
tools/lvcreate.c
tools/lvmcmdlib.c
tools/lvmcmdline.c
tools/toollib.c
tools/vgreduce.c

index 0494ee4b382335976c375f3803dcea2c26f727ba..c5cd4618a31166e35e2bb47379372ff3ed9680e1 100644 (file)
@@ -51,9 +51,6 @@
 */
 
 #include "clvmd-common.h"
-
-#include <pthread.h>
-
 #include "clvmd-comms.h"
 #include "clvm.h"
 #include "clvmd.h"
index 2ffe7f4d48fd5232f4ff01355283368826dd2d80..13148c3a2a23b31624cb7c715b0264070de91435 100644 (file)
@@ -39,8 +39,6 @@
 #include <arpa/inet.h>         /* for htonl, ntohl */
 
 #ifdef linux
-#  include <malloc.h>
-
 /*
  * Kernel version 2.6.36 and higher has
  * new OOM killer adjustment interface.
index 1bde50ea61fb0f8c858603fc0c960baacc6b1706..5d5a46b802ca1ef88fee4d7a35276c660f2fc3c9 100644 (file)
@@ -16,8 +16,6 @@
 #include "log.h"
 
 #include "lvm2cmd.h"
-#include "errors.h"
-#include "libdevmapper-event.h"
 #include "dmeventd_lvm.h"
 
 #include <pthread.h>
index 0c59e340ae8b6541f59987c5343d5b8207d8d889..205218abb7ae089c4c3a8e62f487be5ac51198f1 100644 (file)
@@ -19,8 +19,6 @@
 #include "libdevmapper-event.h"
 #include "dmeventd_lvm.h"
 
-#include "lvm-string.h"
-
 #include <sys/wait.h>
 #include <syslog.h> /* FIXME Replace syslog with multilog */
 /* FIXME Missing openlog? */
index 4bdad232c2005f0d5cf476bf4093de5fa63a0f57..5a408a86946d74ced35c401f7e46cc913d311524 100644 (file)
@@ -19,8 +19,6 @@
 #include "libdevmapper-event.h"
 #include "dmeventd_lvm.h"
 
-#include "lvm-string.h"
-
 #include <sys/wait.h>
 #include <syslog.h> /* FIXME Replace syslog with multilog */
 /* FIXME Missing openlog? */
index d06ff46a98b18e772cdf18da88e50db6d7a513b2..3ca3fd52e3d8de81bc83a98b4d4cc833e57f7f3d 100644 (file)
@@ -21,7 +21,6 @@
 
 #include <assert.h>
 #include <pthread.h>
-#include <malloc.h>
 #include <stdint.h>
 #include <unistd.h>
 
index 5252658ecdb026f8c18d539132b57e2fd8e2b47f..82f700b1018763e44edf8c16422c8b90237c010e 100644 (file)
@@ -103,7 +103,6 @@ SOURCES =\
        misc/lvm-string.c \
        misc/lvm-wrappers.c \
        misc/lvm-percent.c \
-       misc/util.c \
        mm/memlock.c \
        report/properties.c \
        report/report.c \
index 40b0edc8bc71c92ac9115ba6fac83483acf0aca6..122741c195790287d718f2fa9014d285b236bac3 100644 (file)
@@ -14,7 +14,6 @@
  */
 
 #include "lib.h"
-#include "str_list.h"
 #include "dev_manager.h"
 #include "lvm-string.h"
 #include "fs.h"
index 3384ec4fa985a444c0df36459623c291624aa95e..bb949b5e349cd0d9c7d613ff6751ff57cd43145d 100644 (file)
@@ -20,7 +20,6 @@
 #include "lvmcache.h"
 #include "lvmetad-client.h"
 #include "format-text.h" // TODO for disk_locn, used as a DA representation
-#include "filter.h"
 
 static int _using_lvmetad = 0;
 static daemon_handle _lvmetad;
index 60ae6c8b6444817ed01e4be95b2e7d504c6d51a3..a7bda9780839cd7aa1d837dc3966f41519403177 100644 (file)
 #include "device.h"
 #include "str_list.h"
 #include "toolcontext.h"
-#include "lvm-string.h"
 #include "lvm-file.h"
 
 #include <sys/stat.h>
 #include <sys/mman.h>
 #include <unistd.h>
 #include <fcntl.h>
-#include <ctype.h>
 #include <assert.h>
 
 struct config_file {
index f742bfe1a8fefdb04dc45a339a41fbe478643830..346b60a0aff93c38b69b58c837398b44b825fab0 100644 (file)
@@ -14,8 +14,6 @@
 
 #include "lib.h"
 #include "metadata.h"
-#include "xlate.h"
-#include "filter.h"
 
 #ifdef linux
 
index a2fbc4d6dfaf34084d080f2c837bfa8c186fbee3..179f1a6fd10df5b6db9cd559046ee595ec848a29 100644 (file)
 #include "toolcontext.h"
 #include "segtype.h"
 #include "display.h"
-#include "text_export.h"
-#include "text_import.h"
 #include "config.h"
 #include "str_list.h"
-#include "targets.h"
-#include "lvm-string.h"
 #include "activate.h"
 #include "str_list.h"
-#include "metadata.h"
 
 static const char *_errseg_name(const struct lv_segment *seg)
 {
index 5cd8fb2335f7f9f9f2f445068a598f340971c486..e3e88f11329273bc481cb9ac259941eb3ae57242 100644 (file)
@@ -15,7 +15,6 @@
 
 #include "lib.h"
 #include "filter-md.h"
-#include "metadata.h"
 
 #ifdef linux
 
index 112e77cc2274685b86266528e68d1566c6766648..ebd16a2bad0448160a7e17a4e0da4ee48e0330a3 100644 (file)
@@ -14,7 +14,6 @@
 
 #include "lib.h"
 #include "filter-sysfs.h"
-#include "lvm-string.h"
 
 #ifdef linux
 
index 1370d12360ebce622f58c9631349fe02d51bdebe..5c5d890679470479070aa4cff21d56a450279b93 100644 (file)
@@ -25,7 +25,6 @@
 #include "segtype.h"
 #include "pv_alloc.h"
 #include "display.h"
-#include "lvmcache.h"
 #include "metadata.h"
 
 #include <time.h>
index f7f619e844bb20180068e03b3f45d526b2f8bcbe..480fa1c29c47b4dcc34e0da42d291d24316cb844 100644 (file)
@@ -16,7 +16,6 @@
 #include "lib.h"
 #include "label.h"
 #include "metadata.h"
-#include "lvmcache.h"
 #include "disk_rep.h"
 #include "sptype_names.h"
 #include "lv_alloc.h"
index 2d34e6085b2886eeb1a17740863fe8e6c2851708..7059b9830aa2d580db067d5a503ac7a2834de2fa 100644 (file)
@@ -16,7 +16,6 @@
 #include "lib.h"
 #include "label.h"
 #include "metadata.h"
-#include "xlate.h"
 #include "disk_rep.h"
 #include "pool_label.h"
 
index c9611501d92fa07d2d258476b4e350f2bd3d8cf0..18fe577065c4dc346b854d60aa8bbfd7da9adc10 100644 (file)
@@ -25,7 +25,6 @@
 #include <dirent.h>
 #include <unistd.h>
 #include <sys/stat.h>
-#include <sys/file.h>
 #include <fcntl.h>
 #include <time.h>
 
index 13d242aa01028858549f2af9a7d0f6634d428f0a..ccefb4cea032f03f0a57c60b19de94f90c3df370 100644 (file)
@@ -16,7 +16,6 @@
 #include "lib.h"
 #include "archiver.h"
 #include "format-text.h"
-#include "lvm-file.h"
 #include "lvm-string.h"
 #include "lvmcache.h"
 #include "toolcontext.h"
index aea03c9dc2665b674124329b8c954f9332a8803a..d706c2bb9b3b0058d727d041232b2a91ef019b49 100644 (file)
 #include "crc.h"
 #include "xlate.h"
 #include "label.h"
-#include "memlock.h"
 #include "lvmcache.h"
 #include "lvmetad.h"
 
 #include <unistd.h>
-#include <sys/file.h>
 #include <sys/param.h>
 #include <limits.h>
 #include <dirent.h>
index 3d2f496165dcbe5b848c7c9ea79a8d1d1cfeb5dd..8a05ca9f7f0bb5a62a7337b6fdf408e8e7519749 100644 (file)
@@ -16,9 +16,6 @@
 #include "lib.h"
 #include "metadata.h"
 #include "import-export.h"
-#include "display.h"
-#include "toolcontext.h"
-#include "lvmcache.h"
 
 /* FIXME Use tidier inclusion method */
 static struct text_vg_version_ops *(_text_vsn_list[2]);
index 7b2659c5fde6641e9ea8bd331762fc3843cd3a35..f53aa0d55852798bf1a3fac31d6a61fd3fb241ec 100644 (file)
@@ -19,7 +19,6 @@
 #include "label.h"
 #include "xlate.h"
 #include "lvmcache.h"
-#include "lvmetad.h"
 
 #include <sys/stat.h>
 #include <fcntl.h>
index 6fbad7ec73376232668a2d40ee6c386d8583aa44..1dce24370e3399333f2822187be40f785147cb8a 100644 (file)
 #include "lib.h"
 #include "toolcontext.h"
 #include "segtype.h"
-#include "display.h"
-#include "text_export.h"
-#include "text_import.h"
-#include "config.h"
-#include "str_list.h"
-#include "targets.h"
-#include "lvm-string.h"
-#include "activate.h"
-#include "str_list.h"
-#include "metadata.h"
 
 static const char *_freeseg_name(const struct lv_segment *seg)
 {
index c36f1e799b5237e5c1c03e6370208535292a75ee..d50cb4a42a199f26ffa1ed813401676e429c44d0 100644 (file)
 #include "lib.h"
 #include "device.h"
 #include "memlock.h"
-#include "lvm-string.h"
-#include "lvm-file.h"
 #include "defaults.h"
-#include "config.h"
 
 #include <stdarg.h>
 #include <syslog.h>
index 4183046f6cd5bc2fd837d31a94a736abc86d5209..cc906d1f604d58f981f55c3b2f9d380d92544779 100644 (file)
@@ -15,7 +15,6 @@
 
 #include "lib.h"
 #include "metadata.h"
-#include "toolcontext.h"
 #include "lv_alloc.h"
 #include "pv_alloc.h"
 #include "str_list.h"
index c14125aaf4c350188327675c5d0d90ecf93e8f7c..dd029acafcbd9c9b599b5894adde1cf09cb958e1 100644 (file)
@@ -30,7 +30,6 @@
 #include "locking.h"
 #include "archiver.h"
 #include "defaults.h"
-#include "filter-persistent.h"
 
 #include <math.h>
 #include <sys/param.h>
index 0997c5880d89fe47958d4b0d5bf4e3f484361c68..ac885d6dd35304a9ff1cb4607059992fcbdbe9c5 100644 (file)
@@ -24,7 +24,6 @@
 #include "lvm-string.h"
 #include "str_list.h"
 #include "locking.h"   /* FIXME Should not be used in this file */
-#include "memlock.h"
 
 #include "defaults.h" /* FIXME: should this be defaults.h? */
 
index e3fe2723abf27499df47700bf9fec61f78d2ddf9..e85a2bc53a077d79c8e7a696188b4baf13ee8b2c 100644 (file)
@@ -17,9 +17,7 @@
 #include "metadata.h"
 #include "pv_alloc.h"
 #include "toolcontext.h"
-#include "archiver.h"
 #include "locking.h"
-#include "lvmcache.h"
 #include "defaults.h"
 
 static struct pv_segment *_alloc_pv_segment(struct dm_pool *mem,
index 29d235f3a3b77928aafe3774b6a9c2b9257b5b48..48a601e93e66d57e23d6b47ec43935cbf76c717c 100644 (file)
@@ -15,7 +15,6 @@
 
 #include "lib.h"
 #include "pv_map.h"
-#include "pv_alloc.h"
 
 #include <assert.h>
 
index a3d6709caddf426947ce5cbaf37a1c0e7d1550c8..c86bb9a79783df91f58da275ffbc77ae2b92acae 100644 (file)
 #include "toolcontext.h"
 #include "segtype.h"
 #include "display.h"
-#include "archiver.h"
 #include "activate.h"
 #include "lv_alloc.h"
 #include "lvm-string.h"
-#include "str_list.h"
-#include "memlock.h"
 
 #define RAID_REGION_SIZE 1024
 
index 28e4a1db26df4703a1de92cf04cc4f0909684d89..7ce847595e036021ff4f30c490d12decdad99636 100644 (file)
@@ -25,7 +25,6 @@
 #include "lvm-string.h"
 #include "targets.h"
 #include "activate.h"
-#include "sharedlib.h"
 #include "str_list.h"
 
 #include <sys/utsname.h>
index d71737b7f9ea9e1f381618543aef1a169b9b1d2e..b8e49cb343a43548f188f8cfb82cc52ea0e80d17 100644 (file)
@@ -15,7 +15,6 @@
 
 #include "lib.h"
 #include "lvm-file.h"
-#include "lvm-string.h"
 
 #include <unistd.h>
 #include <sys/stat.h>
index e1512f9042265b5d773c152603f553578c8e7029..1c72f85afd235aa72742798af7677b1339fe2bbe 100644 (file)
@@ -17,7 +17,6 @@
 #include "device.h"
 #include "memlock.h"
 #include "lvm-string.h"
-#include "lvm-file.h"
 #include "defaults.h"
 #include "metadata-exported.h"
 
index 48fa522b3d8d9b5d36d2efe04fe77174447c5985..4c2d17824b42e796ded127dec21accdbb2c38341 100644 (file)
@@ -15,9 +15,7 @@
 
 #include "lib.h"
 #include "config.h"
-#include "lvm-string.h"
 #include "sharedlib.h"
-#include "toolcontext.h"
 
 #include <limits.h>
 #include <sys/stat.h>
diff --git a/lib/misc/util.c b/lib/misc/util.c
deleted file mode 100644 (file)
index 75c7afa..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * Copyright (C) 2007 Red Hat, Inc. All rights reserved.
- *
- * This file is part of LVM2.
- *
- * This copyrighted material is made available to anyone wishing to use,
- * modify, copy, or redistribute it subject to the terms and conditions
- * of the GNU Lesser General Public License v.2.1.
- *
- * You should have received a copy of the GNU Lesser General Public License
- * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
- */
-
-/*
- * Return the address of the last file name component of NAME.
- * If NAME ends in a slash, return the empty string.
- */
-
-#include "lib.h"
-
-/* empty for now.  */
index 2571e81351dd5edbc5804a6522b2233fd50c950e..76bdbcaedba4427f68709937ff787b3628a20372 100644 (file)
 #include "metadata.h"
 #include "segtype.h"
 #include "text_export.h"
-#include "text_import.h"
-#include "config.h"
 #include "activate.h"
 #include "str_list.h"
 #ifdef DMEVENTD
-#  include "sharedlib.h"
 #  include "libdevmapper-event.h"
 #endif
 
index a8553d205559b5da225fddae68c0cb860ac0d1f7..eeca282c9be5a77a7d413c31563f41e4cbd7d17a 100644 (file)
@@ -21,7 +21,6 @@
 #include "display.h"
 #include "activate.h"
 #include "segtype.h"
-#include "str_list.h"
 #include "lvmcache.h"
 
 #include <stddef.h> /* offsetof() */
index d95b68ea465a11136e8f435a6f2a9a575f8ea4ad..8aa8121ae37a803ec574b540e1616eaab1c99dd3 100644 (file)
 #include "metadata.h"
 #include "segtype.h"
 #include "text_export.h"
-#include "text_import.h"
 #include "config.h"
 #include "activate.h"
 #include "str_list.h"
 #include "defaults.h"
 
 #ifdef DMEVENTD
-#  include "sharedlib.h"
 #  include "libdevmapper-event.h"
 #endif
 
index 8f5c8096c674bb02bcc1899e754077c3f5391010..f2a65eb82a972bac4201f17beb82653c7af7d705 100644 (file)
 #include "segtype.h"
 #include "display.h"
 #include "text_export.h"
-#include "text_import.h"
 #include "config.h"
-#include "str_list.h"
-#include "targets.h"
-#include "lvm-string.h"
 #include "activate.h"
-#include "str_list.h"
-#include "metadata.h"
 
 static const char *_unknown_name(const struct lv_segment *seg)
 {
index 9611e9bb07db4f6d4e8bb78ac08f75e62eb29b2d..473daa0466c46be088bd438a13aacc249553d2a3 100644 (file)
 #include "toolcontext.h"
 #include "segtype.h"
 #include "display.h"
-#include "text_export.h"
-#include "text_import.h"
 #include "config.h"
 #include "str_list.h"
-#include "targets.h"
-#include "lvm-string.h"
 #include "activate.h"
-#include "metadata.h"
 
 static const char *_zero_name(const struct lv_segment *seg)
 {
index 031ce5eebcf08394d57742a7bc864b81df46f89d..503b24031a97aea76365a3ffdab2535d30abeb2e 100644 (file)
@@ -16,7 +16,6 @@
 #include "libdm-targets.h"
 #include "libdm-common.h"
 #include "kdev_t.h"
-#include "dm-ioctl.h"
 
 #include <stdarg.h>
 #include <sys/param.h>
index 7d1f2a13b09345cdcaf624d211462997dafe709d..0734dedcdb84fe13d37915412c3834def50366fe 100644 (file)
@@ -30,7 +30,6 @@
 #include <dirent.h>
 #include <errno.h>
 #include <unistd.h>
-#include <libgen.h>
 #include <sys/wait.h>
 #include <unistd.h>
 #include <sys/param.h>
index 6aecf1d09d969057859c7fb2a6971d266f2bab6f..769ac8cbe78dcdb1f4f48c6cffb0151d13c381eb 100644 (file)
@@ -14,7 +14,6 @@
  */
 
 #include "tools.h"
-#include "lv_alloc.h"
 
 #include <fcntl.h>
 
index 47bf1c888062d0ccad6e1984f30b0b1d63656303..6b641c2394075fe0d1a1a09d42c61a2ca8c966d4 100644 (file)
 #include "lvm2cmdline.h"
 #include "label.h"
 #include "memlock.h"
-#include "lvm-version.h"
 
 #include "lvm2cmd.h"
 
 #include <signal.h>
-#include <syslog.h>
-#include <libgen.h>
 #include <sys/stat.h>
 #include <time.h>
 #include <sys/resource.h>
index 99648170f2542d9e5e81c82fffdf838ca9bae2b8..eea874e9d863c44dd7d817e03e404e2bc7926e00 100644 (file)
 #include "lvm-version.h"
 
 #include "stub.h"
-#include "lvm2cmd.h"
 #include "last-path-component.h"
 
 #include <signal.h>
-#include <syslog.h>
-#include <libgen.h>
 #include <sys/stat.h>
 #include <time.h>
 #include <sys/resource.h>
index 0f6810b61b7e3160d4567e9714c8acf27d290029..d6fc95199e8caa2eefe29c0e7ef71c209617ae6f 100644 (file)
  */
 
 #include "tools.h"
-#include "lv_alloc.h"
-#include "xlate.h"
-
 #include <sys/stat.h>
-#include <sys/wait.h>
 
 const char *command_name(struct cmd_context *cmd)
 {
index ab448e050dae199b5039ea329833e1d51c9f4822..969665136260cfa61be5cedc01cd4de19b1bfa4d 100644 (file)
@@ -14,7 +14,6 @@
  */
 
 #include "tools.h"
-#include "lv_alloc.h"
 
 static int _remove_pv(struct volume_group *vg, struct pv_list *pvl, int silent)
 {
This page took 0.077167 seconds and 5 git commands to generate.