• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 464
  • Last Modified:

blocking or non-blocking socket

How is a socket changed from a non-blocking one to a
blocking socket?  What are the function calls - the
parameters, etc.?
0
ethorn
Asked:
ethorn
1 Solution
 
mlevCommented:
fcntl(sockfd, F_SETFL, fcntl(sockfd, F_GETFL) & ~O_NONBLOCK);

OR

int arg = 0;
ioctl(sockfd, FIONBIO, &arg);
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: Microsoft Office 2010

This course will introduce you to the interfaces and features of Microsoft Office 2010 Word, Excel, PowerPoint, Outlook, and Access. You will learn about the features that are shared between all products in the Office suite, as well as the new features that are product specific.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now