Changeset 1a23f6e in mainline for uspace/srv/net/udp/sock.c
- Timestamp:
- 2012-05-04T10:41:44Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- af42a2b
- Parents:
- 6efb4d2 (diff), d21e935c (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/udp/sock.c
r6efb4d2 r1a23f6e 43 43 #include <ipc/services.h> 44 44 #include <ipc/socket.h> 45 #include <net/modules.h>46 45 #include <net/socket.h> 47 46 #include <ns.h> … … 85 84 86 85 socket = (udp_sockdata_t *)sock_core->specific_data; 87 (void)socket; 86 assert(socket->assoc != NULL); 87 udp_uc_destroy(socket->assoc); 88 88 } 89 89 … … 133 133 assert(sock_core != NULL); 134 134 sock->sock_core = sock_core; 135 136 137 refresh_answer(&answer, NULL); 135 138 136 SOCKET_SET_SOCKET_ID(answer, sock_id); 139 137 140 138 SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE); 141 139 SOCKET_SET_HEADER_SIZE(answer, sizeof(udp_header_t)); 142 answer_call(callid, EOK, &answer, 3); 140 async_answer_3(callid, EOK, IPC_GET_ARG1(answer), 141 IPC_GET_ARG2(answer), IPC_GET_ARG3(answer)); 143 142 } 144 143 … … 368 367 } 369 368 } 370 371 refresh_answer(&answer, NULL);369 370 IPC_SET_ARG1(answer, 0); 372 371 SOCKET_SET_DATA_FRAGMENT_SIZE(answer, FRAGMENT_SIZE); 373 answer_call(callid, EOK, &answer, 2); 372 async_answer_2(callid, EOK, IPC_GET_ARG1(answer), 373 IPC_GET_ARG2(answer)); 374 374 fibril_mutex_unlock(&socket->lock); 375 375 376 out: 376 377 if (addr != NULL) … … 485 486 486 487 log_msg(LVL_DEBUG, "read_data_length <- %zu", length); 488 IPC_SET_ARG2(answer, 0); 487 489 SOCKET_SET_READ_DATA_LENGTH(answer, length); 488 490 SOCKET_SET_ADDRESS_LENGTH(answer, sizeof(addr)); 489 answer_call(callid, EOK, &answer, 3); 490 491 async_answer_3(callid, EOK, IPC_GET_ARG1(answer), 492 IPC_GET_ARG2(answer), IPC_GET_ARG3(answer)); 493 491 494 /* Push one fragment notification to client's queue */ 492 495 udp_sock_notify_data(sock_core); … … 512 515 socket = (udp_sockdata_t *)sock_core->specific_data; 513 516 fibril_mutex_lock(&socket->lock); 514 515 assert(socket->assoc != NULL);516 udp_uc_destroy(socket->assoc);517 517 518 518 rc = socket_destroy(NULL, socket_id, &client->sockets, &gsock, … … 599 599 } 600 600 } 601 602 /* Clean up */ 603 log_msg(LVL_DEBUG, "udp_sock_connection: Clean up"); 604 async_hangup(client.sess); 605 socket_cores_release(NULL, &client.sockets, &gsock, udp_free_sock_data); 601 606 } 602 607
Note:
See TracChangeset
for help on using the changeset viewer.