Fixes a failure to take into account the user's preference with respect to utilized port ranges in XMPP calls. Reported by Mitchell Langs.