commit 1c7a796d340fd00f2595227a2739102894a86295
Author: Vasily Chekalkin <bacek@bacek.com>
Date: Wed Apr 1 07:18:34 2009 +1100
Update examples/io/http.pir to use constants.
diff --git a/examples/io/http.pir b/examples/io/http.pir
index e0035df..4ea5fd9 100644
a
|
b
|
|
19 | 19 | |
20 | 20 | =cut |
21 | 21 | |
| 22 | .include 'socket.pasm' |
| 23 | |
22 | 24 | .sub example :main |
23 | 25 | .local pmc sock |
24 | 26 | .local pmc address |
… |
… |
|
29 | 31 | # create the socket handle |
30 | 32 | print "Creating socket.\n" |
31 | 33 | sock = new 'Socket' |
32 | | sock.'socket'(2, 1, 0) |
| 34 | sock.'socket'(.PIO_PF_INET, .PIO_SOCK_STREAM, .PIO_PROTO_TCP) |
33 | 35 | unless sock goto ERR |
34 | 36 | |
35 | 37 | # Pack a sockaddr_in structure with IP and port |