File: wvsocketpair.h

package info (click to toggle)
wvstreams 4.6.1-5
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 6,972 kB
  • sloc: cpp: 64,200; ansic: 4,154; sh: 4,094; makefile: 545; perl: 402
file content (17 lines) | stat: -rw-r--r-- 471 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#ifndef __WVSOCKETPAIR_H
#define __WVSOCKETPAIR_H

#ifndef _WIN32
#include <sys/socket.h>
#endif

/**
 * Like socketpair(), but works in win32 and doesn't ask you about the
 * protocol (since that's irrelevant, really).  'type' is like the type
 * parameter to socketpair(), and should be either SOCK_DGRAM or SOCK_STREAM.
 * 
 * The return value and errno codes are the same as for socketpair().
 */
int wvsocketpair(int type, int socks[2]);

#endif // __WVSOCKETPAIR_H