From ea04425e77cf6a4b085bb791bead5e1f7fd71b36 Mon Sep 17 00:00:00 2001 From: pk910 Date: Tue, 26 Jul 2011 10:55:25 +0200 Subject: [PATCH] some more bug fixes (linkable version now) --- Uplink/Client.class.php | 4 ++-- Uplink/Uplink.class.php | 6 +++--- main.php | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Uplink/Client.class.php b/Uplink/Client.class.php index c7ecc4c..8a38610 100644 --- a/Uplink/Client.class.php +++ b/Uplink/Client.class.php @@ -107,7 +107,7 @@ class Client { while(($line = @fgets($this->socket)) != null) { $line=trim($line); if(!empty($line)) { - if(DEBUG_RAW) echo"[recv] ".$line."\n"; + echo"[recv] ".$line."\n"; $this->traffic['in'] += strlen($line); $lines[] = $line; if(count($lines) >= self::CLIENT_RECV_MAX_LINES) break; @@ -120,7 +120,7 @@ class Client { public function send($line, $newline = "\r\n") { if($this->socket == null) return; - if(DEBUG_RAW) echo"[send] ".$line."\n"; + echo"[send] ".$line."\n"; $this->traffic['out'] += strlen($line); fwrite($this->socket,$line.$newline); } diff --git a/Uplink/Uplink.class.php b/Uplink/Uplink.class.php index f0637b0..8174790 100644 --- a/Uplink/Uplink.class.php +++ b/Uplink/Uplink.class.php @@ -253,7 +253,7 @@ class Uplink { return; } $new_server = new P10_Server($args[0], substr($args[5],0,2), $this->server, $args[2], $args[3], $args[7]); - $this->server->add_server($new_server); + $this->server->addServer($new_server); $this->flags |= self::FLAG_P10SESSION | self::FLAG_BURST_PENDING; } else { //another server got a new slave server ^^ @@ -263,7 +263,7 @@ class Uplink { return; } $new_server = new P10_Server($args[0], substr($args[5],0,2), $server, $args[2], $args[3], $args[7]); - $server->add_server($new_server); + $server->addServer($new_server); } } @@ -296,7 +296,7 @@ class Uplink { $ident = $args[3]; $host = $args[4]; $modes = implode(" ",array_slice($args, 5, count($args)-8)); - $modes = new UserModeSet($modes); + $modes = new P10_UserModeSet($modes); $ip = Numerics::parseIP($args[count($args)-3]); $realname = $args[count($args)-1]; new P10_User($nick, $numeric, $server, $connect_time, $ident, $host, $ip, $realname, $modes); diff --git a/main.php b/main.php index 42fa0cd..587e730 100644 --- a/main.php +++ b/main.php @@ -29,8 +29,8 @@ require_once("Uplink/Uplink.class.php"); //basicly here is nothing, yet :D $uplink = new Uplink(); -$uplink->setUplinkHost("localhost", 4402); -$uplink->setUplinkServer(5, "php.local.TestNet", "very_weak_password", "Test Server"); +$uplink->setUplinkHost("192.168.2.103", 4401); +$uplink->setUplinkServer(5, "PHP.TestNet", "very_weak_password", "Test Server"); $uplink->initialize(); -- 2.20.1