dave Mon Dec 15 14:41:43 2003 EDT
Modified files:
/phpdoc/en/reference/sockets reference.xml
/phpdoc/en/reference/sockets/functions socket-strerror.xml
Log:
- 0 => SOL_TCP, fixes #26486.
Index: phpdoc/en/reference/sockets/reference.xml
diff -u phpdoc/en/reference/sockets/reference.xml:1.14
phpdoc/en/reference/sockets/reference.xml:1.15
--- phpdoc/en/reference/sockets/reference.xml:1.14 Mon Dec 15 11:53:46 2003
+++ phpdoc/en/reference/sockets/reference.xml Mon Dec 15 14:41:42 2003
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.14 $ -->
+<!-- $Revision: 1.15 $ -->
<reference id="ref.sockets">
<title>Socket functions</title>
<titleabbrev>Sockets</titleabbrev>
@@ -118,7 +118,7 @@
$address = '192.168.1.53';
$port = 10000;
-if (($sock = socket_create(AF_INET, SOCK_STREAM, 0)) < 0) {
+if (($sock = socket_create(AF_INET, SOCK_STREAM, SOL_TCP)) < 0) {
echo "socket_create() failed: reason: " . socket_strerror($sock) . "\n";
}
@@ -190,7 +190,7 @@
$address = gethostbyname('www.example.com');
/* Create a TCP/IP socket. */
-$socket = socket_create(AF_INET, SOCK_STREAM, 0);
+$socket = socket_create(AF_INET, SOCK_STREAM, SOL_TCP);
if ($socket < 0) {
echo "socket_create() failed: reason: " . socket_strerror($socket) . "\n";
} else {
Index: phpdoc/en/reference/sockets/functions/socket-strerror.xml
diff -u phpdoc/en/reference/sockets/functions/socket-strerror.xml:1.4
phpdoc/en/reference/sockets/functions/socket-strerror.xml:1.5
--- phpdoc/en/reference/sockets/functions/socket-strerror.xml:1.4 Sat May 4
01:06:59 2002
+++ phpdoc/en/reference/sockets/functions/socket-strerror.xml Mon Dec 15 14:41:43
2003
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="iso-8859-1"?>
-<!-- $Revision: 1.4 $ -->
+<!-- $Revision: 1.5 $ -->
<!-- splitted from ./en/functions/sockets.xml, last change in rev 1.8 -->
<refentry id="function.socket-strerror">
<refnamediv>
@@ -28,7 +28,7 @@
<programlisting role="php">
<![CDATA[
<?php
-if (false == ($socket = @socket_create(AF_INET, SOCK_STREAM, 0))) {
+if (false == ($socket = @socket_create(AF_INET, SOCK_STREAM, SOL_TCP))) {
echo "socket_create() failed: reason: " . socket_strerror(socket_last_error()) .
"\n";
}