Posted by Anonymous Thu 1st Mar 2007 22:04 - Syntax is PHP - 46 viewsRun this post in the PHP shell
Download | New Post | Modify | Diff | Hide line numbers
PHP parser reported no syntax errors in this post!
Description:
Warning: socket_select(): no resource arrays were passed to select

  1. $sux = socket_create(AF_INET, SOCK_DGRAM, SOL_UDP);
  2. if (!$sux) {
  3.     exit('create error');
  4. }
  5.  
  6. // designate a port on the socket to recieve data
  7. if (!socket_bind($sux, '8', 7838)) {
  8.     exit('bind error');
  9. }
  10.  
  11.  
  12. $suxref[] =& $sux; // create a reference to the socket as an array
  13.  
  14.  
  15. while (1) {
  16.     // let the system take care of polling for UDP data
  17.        socket_select($suxref, $write = NULL, $except = NULL, 100)// sec. timout
  18.     // get the UDPdata with the sender's IP/port   
  19.     $z = @socket_recvfrom($sux, $buf, 512, 0, $ip, $port);
  20.     //if the server is different, check the authlist - this may or may not improve performance
  21. }

PermaLink to this entry https://pastebin.co.uk/11260

The following amendments have been posted:

  1. Anonymous (Thu 1st Mar 2007 22:05)
Posted by Anonymous Thu 1st Mar 2007 22:04 - Syntax is PHP - 46 viewsRun this post in the PHP shell
Download | New Post | Modify | Diff | Hide line numbers

 

Comments: 0