File tree Expand file tree Collapse file tree 1 file changed +9
-11
lines changed
Expand file tree Collapse file tree 1 file changed +9
-11
lines changed Original file line number Diff line number Diff line change @@ -114,20 +114,18 @@ protected function acceptConnection(ConnectionHandlerFactoryInterface $connectio
114114 {
115115 $ clientSocket = @stream_socket_accept ($ this ->serverSocket );
116116
117- if (false === $ clientSocket ) {
118- return ;
119- }
120-
121- stream_set_blocking ($ clientSocket , 0 );
117+ if (false !== $ clientSocket ) {
118+ stream_set_blocking ($ clientSocket , 0 );
122119
123- $ connection = new StreamSocketConnection ($ clientSocket );
124- $ handler = $ connectionHandlerFactory ->createConnectionHandler ($ connection );
120+ $ connection = new StreamSocketConnection ($ clientSocket );
121+ $ handler = $ connectionHandlerFactory ->createConnectionHandler ($ connection );
125122
126- $ id = spl_object_hash ($ connection );
123+ $ id = spl_object_hash ($ connection );
127124
128- $ this ->clientSockets [$ id ] = $ clientSocket ;
129- $ this ->connections [$ id ] = $ connection ;
130- $ this ->connectionHandlers [$ id ] = $ handler ;
125+ $ this ->clientSockets [$ id ] = $ clientSocket ;
126+ $ this ->connections [$ id ] = $ connection ;
127+ $ this ->connectionHandlers [$ id ] = $ handler ;
128+ }
131129 }
132130
133131 /**
You can’t perform that action at this time.
0 commit comments