Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

explain_socket_or_die(3) [debian man page]

explain_socket_or_die(3)				     Library Functions Manual					  explain_socket_or_die(3)

NAME
explain_socket_or_die - create an endpoint and report errors SYNOPSIS
#include <libexplain/socket.h> void explain_socket_or_die(int domain, int type, int protocol); DESCRIPTION
The explain_socket_or_die function is used to call the socket(2) system call. On failure an explanation will be printed to stderr, obtained from explain_socket(3), and then the process terminates by calling exit(EXIT_FAILURE). This function is intended to be used in a fashion similar to the following example: explain_socket_or_die(domain, type, protocol); domain The domain, exactly as to be passed to the socket(2) system call. type The type, exactly as to be passed to the socket(2) system call. protocol The protocol, exactly as to be passed to the socket(2) system call. Returns: This function only returns on success. On failure, prints an explanation and exits. SEE ALSO
socket(2) create an endpoint for communication explain_socket(3) explain socket(2) errors exit(2) terminate the calling process COPYRIGHT
libexplain version 0.52 Copyright (C) 2008 Peter Miller explain_socket_or_die(3)

Check Out this Related Man Page

explain_connect_or_die(3)				     Library Functions Manual					 explain_connect_or_die(3)

NAME
explain_connect_or_die - initiate a connection on a socket and report errors SYNOPSIS
#include <libexplain/connect.h> void explain_connect_or_die(int fildes, const struct sockaddr *serv_addr, int serv_addr_size); DESCRIPTION
The explain_connect_or_die function is used to call the connect(2) system call. On failure an explanation will be printed to stderr, obtained from explain_connect(3), and then the process terminates by calling exit(EXIT_FAILURE). This function is intended to be used in a fashion similar to the following example: explain_connect_or_die(fildes, serv_addr, serv_addr_size); fildes The fildes, exactly as to be passed to the connect(2) system call. serv_addr The serv_addr, exactly as to be passed to the connect(2) system call. serv_addr_size The serv_addr_size, exactly as to be passed to the connect(2) system call. Returns: This function only returns on success. On failure, prints an explanation and exits. SEE ALSO
connect(2) initiate a connection on a socket explain_connect(3) explain connect(2) errors exit(2) terminate the calling process COPYRIGHT
libexplain version 0.52 Copyright (C) 2008 Peter Miller explain_connect_or_die(3)
Man Page

6 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

socket

hi everybody ! i want create server/clients in c++ anyone can give me i little exemple for send a string ? or give me a good site for explain. thx (1 Reply)
Discussion started by: mercutio
1 Replies

2. Programming

read system call

When i read 4 bytes from a socket the read function returns 0 value. what does it mean? How should i know whether a message is available in the socket or not? (1 Reply)
Discussion started by: Madhu Babu
1 Replies

3. IP Networking

socket programming

my system is a stand alone system... i want to try doing socket porgramming..ihave heard that this is usually done during testing... how can i do that....? (6 Replies)
Discussion started by: damn_bkb
6 Replies

4. UNIX for Advanced & Expert Users

problem with socket reading

I am not able to receive the message on socket in the current process when its waiting for its child to exit. code looks something like below //in one thread of the current process //thread 1 =============================================== int numBytes = read(sockid,buf,SIZE); //Now the... (2 Replies)
Discussion started by: swap007
2 Replies

5. Programming

basic socket programming

Hello experts, four machines need to communicate with each other. How can I start the socket programming. Can you please explain me more elaborated way. Thank you for your time and effort in advance (4 Replies)
Discussion started by: radhakuna
4 Replies

6. Debian

Help socket prog

HI Can anyone provide me with codes for file transfer server to client or vice versa? Also please explain how to compile those programs in ubuntu terminal as i am totally new to socket programming. Thanks (0 Replies)
Discussion started by: mayhemtrigger
0 Replies