MCPcopy Create free account
hub / github.com/F-Stack/f-stack / CloseSocket

Method CloseSocket

adapter/micro_thread/mt_notify.cpp:115–127  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

113}
114
115void UdpSessionNtfy::CloseSocket()
116{
117 int osfd = this->GetOsfd();
118 if (osfd > 0)
119 {
120 MtFrame* frame = MtFrame::Instance();
121 frame->KqueueCtrlDel(osfd, KQ_EVENT_READ);
122 frame->KqueueNtfyReg(osfd, NULL);
123 this->DisableInput();
124 this->SetOsfd(-1);
125 close(osfd);
126 }
127}
128
129int UdpSessionNtfy::InputNotify()
130{

Callers

nothing calls this directly

Calls 6

GetOsfdMethod · 0.80
KqueueCtrlDelMethod · 0.80
KqueueNtfyRegMethod · 0.80
DisableInputMethod · 0.80
SetOsfdMethod · 0.80
closeFunction · 0.70

Tested by

no test coverage detected