* Stabilized the session proxy
authorArt Cancro <ajc@citadel.org>
Fri, 31 Oct 2003 05:03:46 +0000 (05:03 +0000)
committerArt Cancro <ajc@citadel.org>
Fri, 31 Oct 2003 05:03:46 +0000 (05:03 +0000)
* Added 100 mode text downloads
* Print server hello banner

ctdlphp/ChangeLog
ctdlphp/sessionproxy.php

index c753f3aef2ffffbe754ce4129db2950a5c3a2c82..dac43a657bc40038026743601dd0d45472e4000d 100644 (file)
@@ -1,4 +1,8 @@
  $Log$
+ Revision 1.2  2003/10/31 05:03:46  ajc
+ * Stabilized the session proxy
+ * Added 100 mode text downloads
+ * Print server hello banner
+
  Revision 1.1  2003/10/31 03:47:13  ajc
  * Initial CVS import
-
index ee4703eb63b8052054d3d3f694e9dc568674ff5c..09e35503a683429702b43b0c6386ff668b1a8220 100755 (executable)
@@ -124,7 +124,13 @@ do {
 
                        if (substr($talkback, 0, 1) == "1") do {
                                $buf = fgets($ctdlsock, 4096);
-                               socket_write($msgsock, $buf, strlen($buf));
+                               if (!$buf) {
+                                       $buf = "000\n" ;
+                               }
+                               else {
+                                       socket_write($msgsock, $buf,
+                                               strlen($buf));
+                               }
                        } while ($buf != "000\n");
 
                }