while( my ($key, $value) = each %$con_hash ) { if ($value == $client) { delete $con_hash{$key}; } }