fix extracting of LinphoneContent from SalBody

This commit is contained in:
Simon Morlat 2013-06-18 22:06:13 +02:00
parent ba53ca3ee6
commit 129bd04fd8
2 changed files with 4 additions and 0 deletions

View file

@ -85,6 +85,7 @@ const LinphoneContent *linphone_content_from_sal_body(LinphoneContent *obj, cons
obj->subtype=(char*)ref->subtype;
obj->data=(void*)ref->data;
obj->size=ref->size;
return obj;
}
return NULL;
}

View file

@ -28,6 +28,8 @@ static const char *subscribe_content="<somexml>blabla</somexml>";
static const char *notify_content="<somexml2>blabla</somexml2>";
void linphone_notify_received(LinphoneCore *lc, LinphoneEvent *lev, const char *eventname, const LinphoneContent *content){
CU_ASSERT_PTR_NOT_NULL_FATAL(content);
CU_ASSERT_TRUE(strcmp(notify_content,(const char*)content->data)==0);
}
void linphone_subscription_state_change(LinphoneCore *lc, LinphoneEvent *lev, LinphoneSubscriptionState state) {
@ -125,6 +127,7 @@ static void subscribe_test_with_args(bool_t terminated_by_subscriber) {
if (terminated_by_subscriber){
linphone_event_terminate(lev);
}else{
CU_ASSERT_PTR_NOT_NULL_FATAL(pauline->lev);
linphone_event_terminate(pauline->lev);
}