connection: improve errro handling for sending THX JNK