When having something in your hands, pressing X while in your inventory on your hands will very-very likely give a client-sided dupe of said item.
This duped item cannot be removed from the inventory without relogging.
The only way get rid of something in your hands and to avoid the duped item is to use the hotbar instead.