GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  LIBOWFAT_IO_GETCOOKIE (3)

NAME

io_getcookie - retrieve cookie

CONTENTS

Syntax
Description

SYNTAX

#include <io.h>

void* io_getcookie(int64 fd);

DESCRIPTION

io_getcookie retrieves a cookie (pointer to some anonymous data structure you associated with this descriptor).

Use io_setcookie(3) to associate a cookie with a descriptor.

If you did not associate a cookie with this descriptor, io_getcookie returns NULL.

The idea is that you put the state associated with a TCP connection you serve in a common struct. Then you do not need to have your own data structure to retrieve the state for a connection, you can just use the data structure io_wait already maintains. The lookup works in constant time and should not cause any cache misses.

SEE ALSO

io_wait(3), io_setcookie(3)
Search for    or go to Top of page |  Section 3 |  Main Index


IO_GETCOOKIE (3) -->

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.