Commit 7a11cf0
committed
SocketWrapper: call close() before mis-reusing connection
Some libraries don't call close() and expect the device will do it on its own when the server closes the connection.
To fix this, the best thing to do would be either to use connectionKeepAlive() or to simply close() the client before conneting again.
For backwards compatibility, let's start from scratch every time connect() is colled twice.1 parent 9619ec8 commit 7a11cf0
1 file changed
+9
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
78 | 78 | | |
79 | 79 | | |
80 | 80 | | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
81 | 90 | | |
82 | 91 | | |
83 | 92 | | |
| |||
0 commit comments