From eaf4403561c5822d3cdcc93092039d49d1c0375e Mon Sep 17 00:00:00 2001 From: Andreas Dilger Date: Sun, 15 Dec 2013 23:26:38 -0500 Subject: [PATCH] ext2fs,blkid: delete unused LIST_HEAD() macro The LIST_HEAD() macro conflicts with the declaration of the same name. Delete the unused LIST_HEAD() macro from the libext2fs and libblkid headers to avoid compiler warnings. It can be replaced by INIT_LIST_HEAD() or LIST_HEAD_INIT() if needed. Signed-off-by: Andreas Dilger Signed-off-by: "Theodore Ts'o" --- lib/blkid/list.h | 5 +---- lib/ext2fs/kernel-list.h | 3 --- 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/lib/blkid/list.h b/lib/blkid/list.h index c1cbfec..26a5ac1 100644 --- a/lib/blkid/list.h +++ b/lib/blkid/list.h @@ -1,4 +1,4 @@ -#if !defined(_BLKID_LIST_H) && !defined(LIST_HEAD) +#if !defined(_BLKID_LIST_H) && !defined(LIST_HEAD_INIT) #define _BLKID_LIST_H #ifdef __cplusplus @@ -27,9 +27,6 @@ struct list_head { #define LIST_HEAD_INIT(name) { &(name), &(name) } -#define LIST_HEAD(name) \ - struct list_head name = LIST_HEAD_INIT(name) - #define INIT_LIST_HEAD(ptr) do { \ (ptr)->next = (ptr); (ptr)->prev = (ptr); \ } while (0) diff --git a/lib/ext2fs/kernel-list.h b/lib/ext2fs/kernel-list.h index e07d06b..01f4f6b 100644 --- a/lib/ext2fs/kernel-list.h +++ b/lib/ext2fs/kernel-list.h @@ -17,9 +17,6 @@ struct list_head { #define LIST_HEAD_INIT(name) { &(name), &(name) } -#define LIST_HEAD(name) \ - struct list_head name = { &name, &name } - #define INIT_LIST_HEAD(ptr) do { \ (ptr)->next = (ptr); (ptr)->prev = (ptr); \ } while (0) -- 1.8.3.1