Path: utzoo!utgpu!water!watmath!clyde!att!osu-cis!killer!ames!ncar!oddjob!mimsy!chris
From: chris@mimsy.UUCP (Chris Torek)
Newsgroups: comp.unix.wizards
Subject: Re: setsockopt -- SO_LINGER parameter?
Message-ID: <12400@mimsy.UUCP>
Date: 11 Jul 88 13:20:55 GMT
References: <4084@saturn.ucsc.edu>
Organization: U of Maryland, Dept. of Computer Science, Coll. Pk., MD 20742
Lines: 19

In article <4084@saturn.ucsc.edu> koreth@ssyx.ucsc.edu (Steven Grimm) writes:
>Does anyone know what kind of value setsockopt() is expecting 
>as a parameter to the SO_LINGER flag?

In 4.2BSD (and hence [old?] SunOS), an `int' which is the linger time.
To turn it off, you must use SO_DONTLINGER.

In 4.3BSD and later, a structure called `linger', defined in :

/*
 * Structure used for manipulating linger option.
 */
struct	linger {
	int	l_onoff;		/* option on/off */
	int	l_linger;		/* linger time */
};
-- 
In-Real-Life: Chris Torek, Univ of MD Comp Sci Dept (+1 301 454 7163)
Domain:	chris@mimsy.umd.edu	Path:	uunet!mimsy!chris