skypiax: insert the delay ONLY if the broken message is 'ERROR 92 CALL: Unrecognised identity': when repeatedly you try to connect to non-existing Skype account in a short period, the Skype client send you back the two halves of the message 'ERROR 92 CALL: Unrecognised identity' inverted in a way that breaks the flux of the API messages. Maybe an anti-spam feature? Anyway, let's try to work around it and restore sanity with a 1 second delay
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@13666 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
7a34d5bafb
commit
e8a262b729
|
@ -381,10 +381,11 @@ int skypiax_signaling_read(private_t * tech_pvt)
|
|||
tech_pvt->skype_callflow = CALLFLOW_STATUS_INPROGRESS;
|
||||
tech_pvt->interface_state = SKYPIAX_STATE_UP;
|
||||
start_audio_threads(tech_pvt);
|
||||
skypiax_sleep(1000);
|
||||
skypiax_sleep(1000); //FIXME
|
||||
sprintf(msg_to_skype, "ALTER CALL %s SET_INPUT PORT=\"%d\"", id,
|
||||
tech_pvt->tcp_cli_port);
|
||||
skypiax_signaling_write(tech_pvt, msg_to_skype);
|
||||
skypiax_sleep(1000); //FIXME
|
||||
sprintf(msg_to_skype, "#output ALTER CALL %s SET_OUTPUT PORT=\"%d\"", id,
|
||||
tech_pvt->tcp_srv_port);
|
||||
skypiax_signaling_write(tech_pvt, msg_to_skype);
|
||||
|
@ -1469,6 +1470,8 @@ void *skypiax_do_skypeapi_thread_func(void *obj)
|
|||
|
||||
buf[i] = '\0';
|
||||
|
||||
DEBUGA_SKYPE ("BUF=|||%s|||\n", SKYPIAX_P_LOG, buf);
|
||||
|
||||
if(an_event.xclient.message_type == atom_begin){
|
||||
|
||||
if(strlen(buffer)){
|
||||
|
@ -1482,9 +1485,12 @@ void *skypiax_do_skypeapi_thread_func(void *obj)
|
|||
if(an_event.xclient.message_type == atom_continue){
|
||||
|
||||
if(!strlen(buffer)){
|
||||
WARNINGA("Got a 'continue' XAtom without a previous 'begin'. It's value (between vertical bars) is=|||%s|||. Let's introduce a 1 second delay.\n", SKYPIAX_P_LOG, buf);
|
||||
DEBUGA_SKYPE("Got a 'continue' XAtom without a previous 'begin'. It's value (between vertical bars) is=|||%s|||\n", SKYPIAX_P_LOG, buf);
|
||||
continue_is_broken=1;
|
||||
skypiax_sleep(1000000); //1 sec
|
||||
if(!strncmp(buf, "ognised identity", 15)) {
|
||||
WARNINGA("Got a 'continue' XAtom without a previous 'begin'. It's value (between vertical bars) is=|||%s|||. Let's introduce a 1 second delay.\n", SKYPIAX_P_LOG, buf);
|
||||
skypiax_sleep(1000000); //1 sec
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue