fix bad enum cast and invalid enum translation

This commit is contained in:
Simon Morlat 2014-03-28 17:12:49 +01:00
parent 1a05114e49
commit 5cff5bebe5
2 changed files with 3 additions and 3 deletions

View file

@ -882,7 +882,7 @@ static void text_received(SalOp *op, const SalMessage *msg){
if (lc->chat_deny_code==LinphoneReasonNone && is_duplicate_msg(lc,msg->message_id)==FALSE){
linphone_core_message_received(lc,op,msg);
}
sal_message_reply(op,lc->chat_deny_code);
sal_message_reply(op,linphone_reason_to_sal(lc->chat_deny_code));
if (!call) sal_op_release(op);
}

View file

@ -1100,9 +1100,9 @@ int linphone_core_get_local_ip_for(int type, const char *dest, char *result){
SalReason linphone_reason_to_sal(LinphoneReason reason){
switch(reason){
case LinphoneReasonNone:
return SalReasonUnknown;
return SalReasonNone;
case LinphoneReasonNoResponse:
return SalReasonUnknown;
return SalReasonRequestTimeout;
case LinphoneReasonForbidden:
return SalReasonForbidden;
case LinphoneReasonDeclined: