Comments (4)
i can see that the patch syntax does not format correctly !
so here again :
in function clientConnected()
replace
$this->serverClients[$port] = $ip;
by
$this->serverClients[$ip.":".$port] = date("U");
and symetrically in function clientDisconnected()
replace
unset($this->serverClients[$port]);
by
unset($this->serverClients[$ip.":".$port]);
from php-websocket.
Hello Dan.
I'm not entirely sure if it is even possible that the Socket-Handling of the OS assigns the same port to multiple IPs in this case. Nevertheless I added a fix to a branch for a new version. Please check if this solves your problem.
from php-websocket.
Hello Nekudo,
i had the case 2 or 3 times this past week, ( i was running programs with lot of connection to the websocket server ! )
i confirm that it is possible to have the same socket destination port with different IP !
thank you for the fix.
from php-websocket.
Fixed in v2.1.0
from php-websocket.
Related Issues (20)
- how to send cert connect wss:// HOT 9
- Publish on packagist HOT 1
- Use php5 HOT 1
- How to keep long connection? HOT 1
- Server drops messages HOT 3
- Adding a Client.php Message Listener HOT 3
- WebSocketServer behind haproxy HOT 3
- Typo HOT 1
- socket_create(): Unable to create socket [10047]: An address incompatible with the requested protocol was used HOT 9
- socket_bind creates file in /tmp, but www-data has no permissions to it HOT 1
- Missing client documentation HOT 1
- Do not accept new connection after running for a while (+/- 1h)
- Can't set timer
- Class "Bloatless\WebSocket\Examples\Application\Chat" not found HOT 1
- PHP Warning: Private methods cannot be final as they are never overridden by other classes
- how to do private message using php-websocket Bloatless V2.0 ? HOT 2
- how to implement private chat in DemoApplication as in StatusAplication?
- Release v3.0.2 HOT 2
- Possibility to close a Websocket Server?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from php-websocket.