credential-manager: Prefer local over global sets
Invert set enumeration order to first enumerate local and then global credential sets.
This commit is contained in:
committed by
Tobias Brunner
parent
08b19dd02a
commit
6a8a44be88
@@ -166,19 +166,19 @@ METHOD(enumerator_t, sets_enumerate, bool,
|
|||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (this->global)
|
if (this->local)
|
||||||
{
|
{
|
||||||
if (this->global->enumerate(this->global, set))
|
if (this->local->enumerate(this->local, set))
|
||||||
{
|
{
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
/* end of global sets, look for local */
|
/* end of local sets, look for global */
|
||||||
this->global->destroy(this->global);
|
this->local->destroy(this->local);
|
||||||
this->global = NULL;
|
this->local = NULL;
|
||||||
}
|
}
|
||||||
if (this->local)
|
if (this->global)
|
||||||
{
|
{
|
||||||
return this->local->enumerate(this->local, set);
|
return this->global->enumerate(this->global, set);
|
||||||
}
|
}
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user