| 759 | |
| 760 | |
| 761 | int t_write_req(struct sip_msg* msg, struct tw_info* info, str* vm_fifo) |
| 762 | { |
| 763 | str vm_fifo_nt; |
| 764 | |
| 765 | if (assemble_msg(msg, info) < 0) { |
| 766 | LM_ERR("failed to assemble_msg\n"); |
| 767 | return -1; |
| 768 | } |
| 769 | |
| 770 | if (pkg_nt_str_dup(&vm_fifo_nt, vm_fifo) < 0) { |
| 771 | LM_ERR("No more pkg memory\n"); |
| 772 | return -1; |
| 773 | } |
| 774 | |
| 775 | if (write_to_fifo(vm_fifo_nt.s, TWRITE_PARAMS) == -1) { |
| 776 | LM_ERR("write_to_fifo failed\n"); |
| 777 | pkg_free(vm_fifo_nt.s); |
| 778 | return -1; |
| 779 | } |
| 780 | |
| 781 | /* make sure that if voicemail does not initiate a reply |
| 782 | * timely, a SIP timeout will be sent out */ |
| 783 | if (add_blind_uac() == -1) { |
| 784 | LM_ERR("add_blind failed\n"); |
| 785 | pkg_free(vm_fifo_nt.s); |
| 786 | return -1; |
| 787 | } |
| 788 | |
| 789 | pkg_free(vm_fifo_nt.s); |
| 790 | return 1; |
| 791 | } |
| 792 | |
| 793 | |
| 794 | int t_write_unix(struct sip_msg* msg, struct tw_info* info, str* socket) |
nothing calls this directly
no test coverage detected