diff options
author | Mike Buland <eichlan@xagasoft.com> | 2010-10-16 03:02:11 +0000 |
---|---|---|
committer | Mike Buland <eichlan@xagasoft.com> | 2010-10-16 03:02:11 +0000 |
commit | 9031e2af7dd4e65ec70890ee78a7cf600d1b2cc5 (patch) | |
tree | 17bc9d96b13d16d79385016c087321fc1267743f /src/tests/socketblock.cpp | |
parent | 93c028162318a00b9bd03fc4a48383f830cc529d (diff) | |
download | libbu++-9031e2af7dd4e65ec70890ee78a7cf600d1b2cc5.tar.gz libbu++-9031e2af7dd4e65ec70890ee78a7cf600d1b2cc5.tar.bz2 libbu++-9031e2af7dd4e65ec70890ee78a7cf600d1b2cc5.tar.xz libbu++-9031e2af7dd4e65ec70890ee78a7cf600d1b2cc5.zip |
Many, many changes. Documentation changes, renamed the socket class to
TcpSocket, fixed many other things, and finally removed ParamProc. Anything
that needs it will now have to switch to OptParser.
Diffstat (limited to 'src/tests/socketblock.cpp')
-rw-r--r-- | src/tests/socketblock.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/tests/socketblock.cpp b/src/tests/socketblock.cpp index a1ea18d..793ef96 100644 --- a/src/tests/socketblock.cpp +++ b/src/tests/socketblock.cpp | |||
@@ -6,8 +6,8 @@ | |||
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include "bu/ito.h" | 8 | #include "bu/ito.h" |
9 | #include "bu/socket.h" | 9 | #include "bu/tcpsocket.h" |
10 | #include "bu/serversocket.h" | 10 | #include "bu/tcpserversocket.h" |
11 | #include <stdio.h> | 11 | #include <stdio.h> |
12 | #include <unistd.h> | 12 | #include <unistd.h> |
13 | 13 | ||
@@ -21,7 +21,7 @@ public: | |||
21 | 21 | ||
22 | virtual void run() | 22 | virtual void run() |
23 | { | 23 | { |
24 | Bu::Socket c = s.accept( 45, 0 ); | 24 | Bu::TcpSocket c = s.accept( 45, 0 ); |
25 | printf("TstServer: Accetped connection.\n"); fflush( stdout ); | 25 | printf("TstServer: Accetped connection.\n"); fflush( stdout ); |
26 | 26 | ||
27 | sleep( 1 ); | 27 | sleep( 1 ); |
@@ -35,7 +35,7 @@ public: | |||
35 | c.close(); | 35 | c.close(); |
36 | } | 36 | } |
37 | 37 | ||
38 | Bu::ServerSocket s; | 38 | Bu::TcpServerSocket s; |
39 | }; | 39 | }; |
40 | 40 | ||
41 | int main() | 41 | int main() |
@@ -45,7 +45,7 @@ int main() | |||
45 | ts.start(); | 45 | ts.start(); |
46 | 46 | ||
47 | printf("main: Connecting to server.\n"); fflush( stdout ); | 47 | printf("main: Connecting to server.\n"); fflush( stdout ); |
48 | Bu::Socket s( "localhost", 55678 ); | 48 | Bu::TcpSocket s( "localhost", 55678 ); |
49 | 49 | ||
50 | printf("main: Sending 4 bytes.\n"); fflush( stdout ); | 50 | printf("main: Sending 4 bytes.\n"); fflush( stdout ); |
51 | s.write( "aoeu", 4 ); | 51 | s.write( "aoeu", 4 ); |