Skip to content

Commit

Permalink
Merge pull request #15 from monich/no-empty-subject
Browse files Browse the repository at this point in the history
[mms_task_encode] Don't encode empty subject
  • Loading branch information
Slava Monich committed Apr 3, 2014
2 parents 341ec2d + 35f8891 commit ae37842
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion mms-lib/src/mms_task_encode.c
Expand Up @@ -152,7 +152,9 @@ mms_encode_job_encode(
mms->sr.to = g_strdup(enc->to);
mms->sr.cc = g_strdup(enc->cc);
mms->sr.bcc = g_strdup(enc->bcc);
mms->sr.subject = g_strdup(enc->subject);
if (enc->subject && enc->subject[0]) {
mms->sr.subject = g_strdup(enc->subject);
}
mms->sr.dr = ((flags & MMS_SEND_FLAG_REQUEST_DELIVERY_REPORT) != 0);
mms->sr.rr = ((flags & MMS_SEND_FLAG_REQUEST_READ_REPORT) != 0);
mms->sr.content_type = mms_unparse_http_content_type((char**)ct);
Expand Down
2 changes: 1 addition & 1 deletion mms-send/mms-send.c
Expand Up @@ -105,7 +105,7 @@ int main(int argc, char* argv[])
int ret = RET_ERR_CMDLINE;
gboolean ok, verbose = FALSE, dr = FALSE, rr = FALSE;
GError* error = NULL;
char* subject = NULL;
char* subject = "";
GOptionEntry entries[] = {
{ "verbose", 'v', 0, G_OPTION_ARG_NONE, &verbose,
"Enable verbose output", NULL },
Expand Down

0 comments on commit ae37842

Please sign in to comment.