Changeset 4a0bc99 in mainline
- Timestamp:
- 2016-03-30T09:47:15Z (9 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 88ab6e9
- Parents:
- 83e69b9
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/tcp/pdu.c
r83e69b9 r4a0bc99 324 324 size_t text_size; 325 325 uint16_t checksum; 326 int rc; 326 327 327 328 npdu = tcp_pdu_new(); … … 331 332 npdu->src = epp->local.addr; 332 333 npdu->dest = epp->remote.addr; 333 tcp_header_encode(epp, seg, &npdu->header, &npdu->header_size); 334 rc = tcp_header_encode(epp, seg, &npdu->header, &npdu->header_size); 335 if (rc != EOK) { 336 free(npdu); 337 return rc; 338 } 334 339 335 340 text_size = tcp_segment_text_size(seg); 336 341 npdu->text = calloc(1, text_size); 337 if (npdu->text == NULL) 342 if (npdu->text == NULL) { 343 free(npdu->header); 344 free(npdu); 338 345 return ENOMEM; 346 } 339 347 340 348 npdu->text_size = text_size;
Note:
See TracChangeset
for help on using the changeset viewer.