O'Reilly logo

Linux Socket Programming by Example by Warren W. Gay

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 7. Connection-Oriented Protocols for Clients

You'll recall from the last chapter that there are two basic modes of communication for sockets. They are connection and connectionless modes of communication. In the last chapter, you also saw how the UDP protocol could be used to communicate in a connectionless fashion. In this chapter, you'll put the TCP/IP protocol to use, using a connection-oriented form of communication.

This chapter will introduce you to

  • The advantages of connection-oriented protocols

  • The /etc/services file and its support routines

  • The /etc/protocols file and its support routines

  • The connect(2) function

  • How to write a TCP/IP client program

Before you jump in and write your first client program, however, a quick review and an ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required