When #24625 is fixed, Gabble will call finish_shutdown() several times (once when it moves to Disconnected, and once when its porter_force_close callback fires).
Looks good. I'd have vaguely prefered the deletion of an unnecessary '\n' to be a separate commit, since it's not actually in the same function or anything.
Author: Will Thompson <email@example.com>
Date: Mon Oct 19 18:41:11 2009 +0100
Don't call shut_down() twice on stream errors.
This essentially reverts 63d0cd4, which papered over a bug in Wocky
where the callback passed to wocky_porter_force_close_async() would
never be called in slightly obscure situations.
Reviewed-by: Simon McVittie <firstname.lastname@example.org>