[object] Use vector tail()

This commit is contained in:
Behdad Esfahbod 2022-11-20 14:10:39 -07:00
parent 76ce390b5a
commit 87a88117c8
1 changed files with 2 additions and 2 deletions

View File

@ -80,7 +80,7 @@ struct hb_lockable_set_t
if (item)
{
item_t old = *item;
*item = std::move (items[items.length - 1]);
*item = std::move (items.tail ());
items.pop ();
l.unlock ();
old.fini ();
@ -123,7 +123,7 @@ struct hb_lockable_set_t
l.lock ();
while (items.length)
{
item_t old = items[items.length - 1];
item_t old = items.tail ();
items.pop ();
l.unlock ();
old.fini ();