RTCS

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 
1,344件の閲覧回数
netra
Contributor IV

How the server will know the client(windows) has shutdown the socket ??

Please reply

0 件の賞賛
返信
1 解決策
1,080件の閲覧回数
butok
NXP Employee
NXP Employee

For UDP server, it should be handled by an application protocol.

For TCP server, the connection is closed automatically, in case of connection graceful shutdown or reset.

If client was physically unplugged and no shutdown was detected by the server, the TCP keep-alive mechanism is used => the connection will be closed in some timeout.

Any manipulations (recv(), send() etc.) with a TCP socket that has closed connection will cause error.

Best regards,

Andrey Butok

元の投稿で解決策を見る

0 件の賞賛
返信
1 返信
1,081件の閲覧回数
butok
NXP Employee
NXP Employee

For UDP server, it should be handled by an application protocol.

For TCP server, the connection is closed automatically, in case of connection graceful shutdown or reset.

If client was physically unplugged and no shutdown was detected by the server, the TCP keep-alive mechanism is used => the connection will be closed in some timeout.

Any manipulations (recv(), send() etc.) with a TCP socket that has closed connection will cause error.

Best regards,

Andrey Butok

0 件の賞賛
返信