mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
filter: use pointers to real addresses
instead of casting values 1 and 2 to pointers which gcc optimization can have problems with.
This commit is contained in:
parent
15826214f9
commit
dd7ebec120
@ -43,12 +43,15 @@ struct pfilter {
|
|||||||
* do this.
|
* do this.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
static int _good_device;
|
||||||
|
static int _bad_device;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The hash table holds one of these two states
|
* The hash table holds one of these two states
|
||||||
* against each entry.
|
* against each entry.
|
||||||
*/
|
*/
|
||||||
#define PF_BAD_DEVICE ((void *) 1)
|
#define PF_BAD_DEVICE ((void *) &_good_device)
|
||||||
#define PF_GOOD_DEVICE ((void *) 2)
|
#define PF_GOOD_DEVICE ((void *) &_bad_device)
|
||||||
|
|
||||||
static int _init_hash(struct pfilter *pf)
|
static int _init_hash(struct pfilter *pf)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user