*** empty log message ***
This commit is contained in:
parent
e60ed679b4
commit
1a1b8ba5e5
|
@ -25,19 +25,19 @@
|
|||
|
||||
#include "mmsbox.h"
|
||||
|
||||
#define MOD_SUBJECT(msg, mmc,xfrom) do { \
|
||||
if ((mmc)->reroute_mod_subject) { \
|
||||
Octstr *s = mms_get_header_value((msg),octstr_imm("Subject")); \
|
||||
Octstr *f = octstr_duplicate(xfrom); \
|
||||
int _i; \
|
||||
if (s == NULL) s = octstr_create(""); \
|
||||
if ((_i = octstr_search(f, octstr_imm("/TYPE="), 0)) >= 0) \
|
||||
octstr_delete(f, _i, octstr_len(f)); \
|
||||
octstr_format_append(s, " (from %S)", (f)); \
|
||||
mms_replace_header_value((msg), "Subject", octstr_get_cstr(s)); \
|
||||
octstr_destroy(s); octstr_destroy(f); \
|
||||
} \
|
||||
} while(0)
|
||||
#define MOD_SUBJECT(msg, mmc,xfrom) do { \
|
||||
if ((mmc)->reroute_mod_subject) { \
|
||||
Octstr *s = mms_get_header_value((msg),octstr_imm("Subject")); \
|
||||
Octstr *f = octstr_duplicate(xfrom); \
|
||||
int _i; \
|
||||
if (s == NULL) s = octstr_create(""); \
|
||||
if ((_i = octstr_search(f, octstr_imm("/TYPE="), 0)) >= 0) \
|
||||
octstr_delete(f, _i, octstr_len(f)); \
|
||||
octstr_format_append(s, " (from %S)", (f)); \
|
||||
mms_replace_header_value((msg), "Subject", octstr_get_cstr(s)); \
|
||||
octstr_destroy(s); octstr_destroy(f); \
|
||||
} \
|
||||
} while(0)
|
||||
|
||||
|
||||
|
||||
|
@ -465,7 +465,7 @@ static int mm7eaif_receive(MmsBoxHTTPClientInfo *h)
|
|||
Octstr *subject = NULL, *otransid = NULL, *msgid = NULL;
|
||||
Octstr *hfrom = NULL, *rr_uri = NULL;
|
||||
time_t expiryt = -1, deliveryt = -1;
|
||||
Octstr *qf = NULL, *xver, *mmc_id = NULL, *qdir = NULL;
|
||||
Octstr *qf = NULL, *xver = NULL, *mmc_id = NULL, *qdir = NULL;
|
||||
int msize = h->body ? octstr_len(h->body) : 0;
|
||||
int dlr;
|
||||
int mtype;
|
||||
|
@ -506,13 +506,13 @@ static int mm7eaif_receive(MmsBoxHTTPClientInfo *h)
|
|||
for (i = 0, n = gwlist_len(hto); i < n; i++) {
|
||||
Octstr *h = NULL, *v = NULL;
|
||||
List *l;
|
||||
int j, m;
|
||||
void *x;
|
||||
|
||||
http_header_get(hto,i, &h, &v);
|
||||
l = http_header_split_value(v);
|
||||
|
||||
for (j = 0, m = gwlist_len(l); j < m; j++)
|
||||
gwlist_append(to, gwlist_get(l, j));
|
||||
while ((x = gwlist_extract_first(l)) != NULL)
|
||||
gwlist_append(to, x);
|
||||
|
||||
gwlist_destroy(l, NULL);
|
||||
octstr_destroy(h);
|
||||
|
@ -622,7 +622,6 @@ static int mm7eaif_receive(MmsBoxHTTPClientInfo *h)
|
|||
if (value2 && mmc_id == NULL)
|
||||
http_header_add(rqh, "X-Mbuni-Orig-Message-ID", octstr_get_cstr(value2));
|
||||
|
||||
|
||||
qf = qfs->mms_queue_add(hfrom, to, NULL,
|
||||
h->m->id, mmc_id,
|
||||
0, time(NULL) + default_msgexpiry, m, NULL,
|
||||
|
@ -635,10 +634,13 @@ static int mm7eaif_receive(MmsBoxHTTPClientInfo *h)
|
|||
NULL);
|
||||
if (qf) {
|
||||
/* Log to access log */
|
||||
mms_log("Received RR", hfrom, to, -1, msgid, value, h->m->id, "MMSBox", h->ua, NULL);
|
||||
mms_log("Received RR", hfrom, to, -1, msgid, value, h->m->id, "MMSBox", h->ua, NULL);
|
||||
hstatus = HTTP_NO_CONTENT;
|
||||
} else
|
||||
hstatus = HTTP_INTERNAL_SERVER_ERROR;
|
||||
|
||||
octstr_destroy(value);
|
||||
octstr_destroy(value2);
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -1156,7 +1158,7 @@ static Octstr *mm7eaif_send(MmscGrp *mmc, Octstr *from, Octstr *to,
|
|||
int mtype = mms_messagetype(m);
|
||||
int hstatus = HTTP_OK;
|
||||
List *rh = http_create_empty_headers(), *ph = NULL;
|
||||
Octstr *body = NULL, *rbody = NULL, *url = NULL, *xver;
|
||||
Octstr *body = NULL, *rbody = NULL, *xver = NULL;
|
||||
char *msgtype;
|
||||
|
||||
|
||||
|
@ -1239,7 +1241,7 @@ static Octstr *mm7eaif_send(MmscGrp *mmc, Octstr *from, Octstr *to,
|
|||
octstr_destroy(body);
|
||||
http_destroy_headers(ph);
|
||||
octstr_destroy(rbody);
|
||||
octstr_destroy(url);
|
||||
|
||||
octstr_destroy(resp);
|
||||
return ret;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue