| 352 | } |
| 353 | |
| 354 | struct mailimf_mailbox * Address::createIMFMailbox() |
| 355 | { |
| 356 | struct mailimf_mailbox * result; |
| 357 | char * display_name; |
| 358 | char * addr_spec; |
| 359 | |
| 360 | display_name = NULL; |
| 361 | if (displayName() != NULL) { |
| 362 | if (displayName()->length() > 0) { |
| 363 | Data * data; |
| 364 | |
| 365 | data = displayName()->encodedAddressDisplayNameValue(); |
| 366 | if (data->bytes() != NULL) { |
| 367 | display_name = strdup(data->bytes()); |
| 368 | } |
| 369 | } |
| 370 | } |
| 371 | addr_spec = strdup(mailbox()->UTF8Characters()); |
| 372 | result = mailimf_mailbox_new(display_name, addr_spec); |
| 373 | |
| 374 | return result; |
| 375 | } |
| 376 | |
| 377 | String * Address::RFC822String() |
| 378 | { |
no test coverage detected