Changes in uspace/srv/net/tcp/sock.c [02a09ed:f4a27304] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/tcp/sock.c
r02a09ed rf4a27304 613 613 ipc_callid_t wcallid; 614 614 size_t length; 615 uint8_t buffer[TCP_SOCK_FRAGMENT_SIZE];616 615 tcp_error_t trc; 617 616 int rc; 617 618 uint8_t *buffer = calloc(TCP_SOCK_FRAGMENT_SIZE, 1); 619 if (buffer == NULL) { 620 async_answer_0(callid, ENOMEM); 621 return; 622 } 618 623 619 624 log_msg(LOG_DEFAULT, LVL_DEBUG, "tcp_sock_send()"); … … 625 630 if (sock_core == NULL) { 626 631 async_answer_0(callid, ENOTSOCK); 627 return;632 goto out; 628 633 } 629 634 … … 641 646 fibril_mutex_unlock(&socket->lock); 642 647 async_answer_0(callid, EINVAL); 643 return;648 goto out; 644 649 } 645 650 … … 651 656 fibril_mutex_unlock(&socket->lock); 652 657 async_answer_0(callid, rc); 653 return;658 goto out; 654 659 } 655 660 … … 676 681 fibril_mutex_unlock(&socket->lock); 677 682 async_answer_0(callid, rc); 678 return;683 goto out; 679 684 } 680 685 } … … 685 690 IPC_GET_ARG2(answer)); 686 691 fibril_mutex_unlock(&socket->lock); 692 693 out: 694 free(buffer); 687 695 } 688 696
Note:
See TracChangeset
for help on using the changeset viewer.