Actually I managed to track this one down. Looks like things get into a bad state if you enter an invalid password once. The client isn't unregistering the existing session (in a 'bad_auth' state) before it tries to reconnect -- and the server doesn't do the right thing at all (it should just drop the existing session and reconnect).
I've added bug 26634 to track this. The fix is checked in and will come out in 5.0.5.
Unfortunately for you, it looks like the account is going to remain stuck until you restart the server - I don't see any way to work around this from the Web Client.
If you're comfortable doing a little bit of scripting, you can manually unregister the account from interop by sending the proper SOAP request
Code:
<IMGatewayRegisterRequest service="yahoo" op="unreg" xmlns:ns0="urn:zimbraIM"/>
to the server. There's a perl script you can run, if you have the source installed somewhere:
Code:
cd <SOURCE_ROOT>/ZimbraServer/src/perl/soap
perl imGatewayRegister.pl -u USERNAME -op unreg -gw yahoo -h http(s)://YOUR_HOST -pw PASSWORD