Changeset 779541b in mainline for uspace/lib/c/generic/inet/udp.c
- Timestamp:
- 2015-05-09T13:43:50Z (10 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 1d4b815
- Parents:
- 99ea91b2
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/inet/udp.c
r99ea91b2 r779541b 42 42 #include <stdlib.h> 43 43 44 #include <stdio.h>45 46 44 static void udp_cb_conn(ipc_callid_t, ipc_call_t *, void *); 47 45 … … 50 48 async_exch_t *exch = async_exchange_begin(udp->sess); 51 49 52 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_callback_create() \n");50 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_callback_create()"); 53 51 54 52 aid_t req = async_send_0(exch, UDP_CALLBACK_CREATE, NULL); … … 71 69 int rc; 72 70 73 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_create() \n");71 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_create()"); 74 72 75 73 udp = calloc(1, sizeof(udp_t)); … … 124 122 ipc_call_t answer; 125 123 126 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_assoc_create() \n");124 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_assoc_create()"); 127 125 128 126 assoc = calloc(1, sizeof(udp_assoc_t)); … … 166 164 async_exch_t *exch; 167 165 168 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_assoc_destroy() \n");166 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_assoc_destroy()"); 169 167 170 168 if (assoc == NULL) … … 186 184 async_exch_t *exch; 187 185 188 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_assoc_send_msg() \n");186 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_assoc_send_msg()"); 189 187 190 188 exch = async_exchange_begin(assoc->udp->sess); … … 277 275 ipc_call_t answer; 278 276 279 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_rmsg_info() \n");277 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_rmsg_info()"); 280 278 281 279 exch = async_exchange_begin(udp->sess); … … 305 303 async_exch_t *exch; 306 304 307 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_rmsg_discard() \n");305 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_rmsg_discard()"); 308 306 309 307 exch = async_exchange_begin(udp->sess); … … 332 330 int rc; 333 331 334 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_ev_data() \n");332 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_ev_data()"); 335 333 336 334 while (true) { 337 335 rc = udp_rmsg_info(udp, &rmsg); 338 336 if (rc != EOK) { 339 log_msg(LOG_DEFAULT, LVL_NOTE, "Error getting message info \n");337 log_msg(LOG_DEFAULT, LVL_NOTE, "Error getting message info"); 340 338 break; 341 339 } … … 343 341 rc = udp_assoc_get(udp, rmsg.assoc_id, &assoc); 344 342 if (rc != EOK) { 345 log_msg(LOG_DEFAULT, LVL_NOTE, "assoc ID %zu not found \n",343 log_msg(LOG_DEFAULT, LVL_NOTE, "assoc ID %zu not found", 346 344 rmsg.assoc_id); 347 345 continue; … … 353 351 rc = udp_rmsg_discard(udp); 354 352 if (rc != EOK) { 355 log_msg(LOG_DEFAULT, LVL_NOTE, "Error discarding message \n");353 log_msg(LOG_DEFAULT, LVL_NOTE, "Error discarding message"); 356 354 break; 357 355 } … … 367 365 async_answer_0(iid, EOK); 368 366 369 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_cb_conn() \n");367 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_cb_conn()"); 370 368 371 369 while (true) { … … 373 371 ipc_callid_t callid = async_get_call(&call); 374 372 375 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_cb_conn() - msg %d \n",373 log_msg(LOG_DEFAULT, LVL_NOTE, "udp_cb_conn() - msg %d", 376 374 (int)IPC_GET_IMETHOD(call)); 377 375 if (!IPC_GET_IMETHOD(call)) {
Note:
See TracChangeset
for help on using the changeset viewer.