diff --git a/mbuni/extras/pgsql-queue/mms_pgsql_queue.c b/mbuni/extras/pgsql-queue/mms_pgsql_queue.c index 9125a2f..4223bcb 100644 --- a/mbuni/extras/pgsql-queue/mms_pgsql_queue.c +++ b/mbuni/extras/pgsql-queue/mms_pgsql_queue.c @@ -66,9 +66,9 @@ static int pgq_init_module(Octstr *conninfo, char *xtopdir, int max_connections) /* Now look for flags */ if ((i = octstr_search_char(xcinfo, ';', 0)) > 0) { - Octstr *x = octstr_copy(xcinfo, 0, i); + Octstr *x = octstr_copy(xcinfo, i, octstr_len(xcinfo)); - octstr_delete(xcinfo, 0, i+1); + octstr_delete(xcinfo, i, octstr_len(xcinfo)); if (octstr_case_search(x, octstr_imm("internal"), 0) >= 0) external_storage = 0; diff --git a/mbuni/mmlib/mms_mm7soap.c b/mbuni/mmlib/mms_mm7soap.c index 3973175..8ab9477 100644 --- a/mbuni/mmlib/mms_mm7soap.c +++ b/mbuni/mmlib/mms_mm7soap.c @@ -706,7 +706,7 @@ int mm7_soapmsg_to_httpmsg(MSoapMsg_t *m, MM7Version_t *ver, List **hdrs, Octstr http_destroy_headers(hx); hx = http_create_empty_headers(); - http_header_add(hx, "Content-Type", "text/xml"); + http_header_add(hx, "Content-Type", "text/xml; charset=utf-8"); http_header_add(hx, "Content-ID", octstr_get_cstr(envloc)); mime_replace_headers(xml, hx); http_destroy_headers(hx); diff --git a/mbuni/mmlib/mms_util.c b/mbuni/mmlib/mms_util.c index d328440..c931d60 100644 --- a/mbuni/mmlib/mms_util.c +++ b/mbuni/mmlib/mms_util.c @@ -3036,14 +3036,14 @@ MmsMsg *make_msg_from_sendmms_request(Octstr *from, List *to, dict_destroy(url_map); /* SMIL has been modified, convert it to text, put it in. */ - xmlDocDumpFormatMemory(smil, &buf, &bsize, 1); + xmlDocDumpFormatMemoryEnc(smil, &buf, &bsize, "utf-8", 1); xmlFreeDoc(smil); if (buf) { MIMEEntity *sm = mime_entity_create(); List *xh = http_create_empty_headers(); Octstr *s; - http_header_add(xh, "Content-Type", "application/smil"); + http_header_add(xh, "Content-Type", "application/smil; charset=utf-8"); http_header_add(xh, "Content-ID", ""); /* identify it as start element. */ if (xmhdr) http_header_add(xh, octstr_get_cstr(xmhdr), octstr_get_cstr(xmhdr_val));