--- a/hedgewars/uGearsList.pas Mon Dec 08 10:55:56 2014 -0500
+++ b/hedgewars/uGearsList.pas Mon Dec 08 11:20:31 2014 -0500
@@ -727,9 +727,8 @@
if lastGearByUID = Gear then
lastGearByUID := nil;
if (Gear^.Hedgehog = nil) or (Gear^.Hedgehog^.GearHidden <> Gear) then // hidden hedgehogs shouldn't be in the list
- RemoveGearFromList(Gear);
-if (Gear^.Hedgehog <> nil) and (Gear^.Hedgehog^.GearHidden = Gear) then
- Gear^.Hedgehog^.GearHidden:= nil;
+ RemoveGearFromList(Gear)
+else Gear^.Hedgehog^.GearHidden:= nil;
Dispose(Gear)
end;