This is a super old bug that I want to bring back to light, I could not find a canny on this.
This bug alone, is responsible for several vehicle woes, often requiring vehicles to be re-rezzed.
Old archived posts referencing this issue:
Summary:
In short, when an agent crashes and disconnects uncleanly, the sit target remains occupied. Other viewers will still show the (now gone) avatar on the seat, scripts who call llAvatarOnSitTarget or related functions will be told that the sit target is occupied by the avatar who got disconnected.
What makes this particularly evil for scripts?
  • This stale state survives script resets, since it's a simulator state issue.
  • The stale sit target survives sim crossings
  • Even worse, you can unlink and relink the link with the sit target, and the simulator will still report that the disconnected avatar is sitting on that sit target once you relink.
  • If the disconnected avatar relogs to a different region, and teleports back to the region the vehicle is in, when they resit, the avatar will now occupy two sit targets.
Side note: If a linden wants help reproducing this bug, I'm happy to help. It can be reproduced easily if we stress test and try to crash on purpose; by having a multi-avatar vehicle with several avatars running several scripts.. we can make ourselves crash onto sim corners.