You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by "zhhyu7 (via GitHub)" <gi...@apache.org> on 2023/07/17 03:42:05 UTC

[GitHub] [nuttx] zhhyu7 opened a new pull request, #9841: net/local: remove client from server.lc_waiters when client close

zhhyu7 opened a new pull request, #9841:
URL: https://github.com/apache/nuttx/pull/9841

   ## Summary
   if client is a noblocking socket, user can do close when server has not yet invoke accept interface, so we need remove this socket from server.lc_waiters. avoid server socket access the freed memory.
   
   ==936564==ERROR: AddressSanitizer: heap-use-after-free on address 0xf23071c8 at pc 0x58eaac3b bp 0xf0b9e218 sp 0xf0b9e208 READ of size 4 at 0xf23071c8 thread T0
       #0 0x58eaac3a in dq_remfirst queue/dq_remfirst.c:45
       #1 0x58fd1efe in local_accept local/local_accept.c:141
       #2 0x58f66df6 in psock_accept socket/accept.c:149
       #3 0x58f672a4 in accept4 socket/accept.c:280
       #4 0x5be9ee0c in accept net/lib_accept.c:50
       #5 0x592d6a5d in uv__accept libuv/src/unix/core.c:502
       #6 0x5930d83b in uv__server_io libuv/src/unix/stream.c:550
       #7 0x592efbde in uv__io_poll libuv/src/unix/posix-poll.c:335
       #8 0x592d649a in uv_run libuv/src/unix/core.c:387
       #9 0x5a7180f7 in service_schedule_loop service/common/service_loop.c:146
       #10 0x591f300b in pthread_startup pthread/pthread_create.c:59
       #11 0x5be8134f in pthread_start pthread/pthread_create.c:139
       #12 0x58ee2762 in pre_start sim/sim_initialstate.c:53
   
   ## Impact
   
   ## Testing
   sim:local
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [nuttx] jerpelea merged pull request #9841: net/local: remove client from server.lc_waiters when client close

Posted by "jerpelea (via GitHub)" <gi...@apache.org>.
jerpelea merged PR #9841:
URL: https://github.com/apache/nuttx/pull/9841


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org