Fix Disconnect() method of Port 92/263892/1
authorHwankyu Jhun <h.jhun@samsung.com>
Mon, 13 Sep 2021 07:14:05 +0000 (16:14 +0900)
committerHwankyu Jhun <h.jhun@samsung.com>
Mon, 13 Sep 2021 07:14:05 +0000 (16:14 +0900)
Before closing the file descriptor, the method calls IgnoreIOEvent() to
release the GSource.

Change-Id: I8e7c91de98e1db838def468564ca98117d1985eb
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
src/port-internal.cc

index 4cceada..582e6a5 100644 (file)
@@ -80,6 +80,8 @@ Port::~Port() {
 }
 
 void Port::Disconnect() {
+  IgnoreIOEvent();
+
   if (fd_ > 0) {
     _W("Close fd(%d)", fd_);
     close(fd_);