Following on from what I said above... I've just added this code to tpl_login_as_customer_default.php
It doesn't stop you from logging in as the wrong customer, but at least it gives you a bit more of a warning before you do it.
PHP Code:
<?php
$cusid = $_SESSION['customer_id'];
if ($cusid){
echo '<div class="messageStackWarning">WARNING you are already logged in as customer: '.$cusid.' - '.$_SESSION['customer_first_name'].' '.$_SESSION['customer_last_name'].' - PLEASE LOG OUT FIRST</div>';
}
?>
It doesn't really matter where you put it, I added it just above where it says: 'Are you sure you want to log in as'
If somebody wants to work out how to safely and properly destroy the session instead, that would be much better.