MCPcopy Create free account
hub / github.com/ansyun/dpdk-ans / accept

Function accept

examples/https_server/ans_module.c:520–542  ·  view source on GitHub ↗

* @param * * @return * */

Source from the content-addressed store, hash-verified

518 *
519 */
520int accept(int sockfd, struct sockaddr *addr, socklen_t *addrlen)
521{
522 int rc;
523
524 if (sockfd > ANS_FD_BASE)
525 {
526 sockfd -= ANS_FD_BASE;
527
528 rc = anssock_accept(sockfd, addr, addrlen);
529 addr->sa_family = AF_INET;
530
531 ANS_FD_DEBUG("ans accept fd %d \n", rc);
532 if(rc > 0 )
533 rc += ANS_FD_BASE;
534 }
535 else
536 {
537 rc = real_accept(sockfd, addr, addrlen);
538 ANS_FD_DEBUG("linux accept fd %d \n", rc);
539
540 }
541 return rc;
542}
543
544/**
545 * @param

Callers 2

mainFunction · 0.85
RunHttpsThreadFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected