Dead call handling
Fix indentation
Factor out SIP-specific code