Fix multiple branch handling logging and early exit

Signed-off-by: Si Beaumont <simon.beaumont@citrix.com>