8.8. TCP Connections

TCP connections are used almost exclusively for network connections in the UNIX world and in general. TCP packets, unlike UDP packets, are automatically sequenced and error-checked by the network drivers, and the system can detect when the connection terminates automatically. The telnet, ftp, finger, and talk commands all rely on point-to-point TCP connections. You can talk to someone on a machine in the next room or halfway around the world if you are connected to the Internet.

TCP connections are very similar to Windows' named pipes, but they allow you to connect to a wide variety of machines on heterogeneous networks. This section demonstrates both point-to-point and client/server architectures. Many parts of the code ...

Get Win32 System Services: The Heart of Windows® 98 and Windows® 2000 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.