mirror of
https://gitlab.linphone.org/BC/public/linphone-iphone.git
synced 2026-01-17 19:18:06 +00:00
fix send of notify multipart
This commit is contained in:
parent
bad6d9e9e1
commit
1572ef97ee
3 changed files with 4 additions and 4 deletions
|
|
@ -324,7 +324,7 @@ LinphoneStatus linphone_event_notify(LinphoneEvent *lev, const LinphoneContent *
|
|||
ms_error("linphone_event_notify(): cannot notify if not an incoming subscription.");
|
||||
return -1;
|
||||
}
|
||||
body_handler = sal_body_handler_from_content(body);
|
||||
body_handler = sal_body_handler_from_content(body, false);
|
||||
auto subscribeOp = dynamic_cast<SalSubscribeOp *>(lev->op);
|
||||
return subscribeOp->notify(body_handler);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -386,7 +386,7 @@ void linphone_configure_op(LinphoneCore *lc, LinphonePrivate::SalOp *op, const L
|
|||
void linphone_configure_op_with_proxy(LinphoneCore *lc, LinphonePrivate::SalOp *op, const LinphoneAddress *dest, SalCustomHeader *headers, bool_t with_contact, LinphoneProxyConfig *proxy);
|
||||
LinphoneContent * linphone_content_new(void);
|
||||
LinphoneContent * linphone_content_copy(const LinphoneContent *ref);
|
||||
SalBodyHandler *sal_body_handler_from_content(const LinphoneContent *content);
|
||||
SalBodyHandler *sal_body_handler_from_content(const LinphoneContent *content, bool parseMultipart = true);
|
||||
SalReason linphone_reason_to_sal(LinphoneReason reason);
|
||||
LinphoneReason linphone_reason_from_sal(SalReason reason);
|
||||
void linphone_error_info_to_sal(const LinphoneErrorInfo* ei, SalErrorInfo* sei);
|
||||
|
|
|
|||
|
|
@ -303,13 +303,13 @@ LinphoneContent *linphone_content_from_sal_body_handler (SalBodyHandler *body_ha
|
|||
return NULL;
|
||||
}
|
||||
|
||||
SalBodyHandler *sal_body_handler_from_content (const LinphoneContent *content) {
|
||||
SalBodyHandler *sal_body_handler_from_content (const LinphoneContent *content, bool parseMultipart) {
|
||||
if (content == NULL) return NULL;
|
||||
|
||||
SalBodyHandler *body_handler;
|
||||
LinphonePrivate::ContentType contentType = L_GET_CPP_PTR_FROM_C_OBJECT(content)->getContentType();
|
||||
|
||||
if (contentType.isMultipart()) {
|
||||
if (contentType.isMultipart() && parseMultipart) {
|
||||
size_t size = linphone_content_get_size(content);
|
||||
char *buffer = bctbx_strdup(L_GET_CPP_PTR_FROM_C_OBJECT(content)->getBodyAsUtf8String().c_str());
|
||||
const char *boundary = L_STRING_TO_C(contentType.getParameter("boundary").getValue());
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue