From ted@colanix0.ga.erg.sri.com  Wed Apr 23 10:33:14 2003
Return-Path: <ted@colanix0.ga.erg.sri.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 3459837B401
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 23 Apr 2003 10:33:14 -0700 (PDT)
Received: from colanix0.ga.erg.sri.com (colanix0.ga.erg.sri.com [192.26.245.70])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 65D1643FE3
	for <FreeBSD-gnats-submit@freebsd.org>; Wed, 23 Apr 2003 10:33:13 -0700 (PDT)
	(envelope-from ted@colanix0.ga.erg.sri.com)
Received: from colanix0.ga.erg.sri.com (localhost [127.0.0.1])
	by colanix0.ga.erg.sri.com (8.12.3/8.12.3) with ESMTP id h3NHXANd075699;
	Wed, 23 Apr 2003 13:33:10 -0400 (EDT)
	(envelope-from ted@colanix0.ga.erg.sri.com)
Received: (from ted@localhost)
	by colanix0.ga.erg.sri.com (8.12.3/8.12.3/Submit) id h3NHX966075698;
	Wed, 23 Apr 2003 13:33:09 -0400 (EDT)
Message-Id: <200304231733.h3NHX966075698@colanix0.ga.erg.sri.com>
Date: Wed, 23 Apr 2003 13:33:09 -0400 (EDT)
From: Ted Nolan <ted@erg.sri.com>
Reply-To: Ted Nolan <ted@erg.sri.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc: ted@erg.sri.com
Subject: Man page for kvm_getprocs(3) omits #include <sys/user.h>
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         51322
>Category:       docs
>Synopsis:       Man page for kvm_getprocs(3) omits #include <sys/user.h>
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    trhodes
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          doc-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Apr 23 10:40:09 PDT 2003
>Closed-Date:    Tue Apr 29 07:38:12 PDT 2003
>Last-Modified:  Tue Apr 29 07:38:12 PDT 2003
>Originator:     Ted Nolan
>Release:        FreeBSD 4.6.2-RELEASE i386
>Organization:
SRI
>Environment:
any
System: FreeBSD colanix0 4.6.2-RELEASE FreeBSD 4.6.2-RELEASE #0: Wed Aug 14 21:23:26 GMT 2002 murray@builder.freebsdmall.com:/usr/src/sys/compile/GENERIC i386


	
>Description:
The man page for kvm_getenvv() (which falls under kvm_getprocs(3), says
you need to
	#include <kvm.h>
	#include <sys/param.h>
	#include <sys/sysctl.h>

before calling the functions listed.  I find you must also
	#include <sys/user.h>

of you will not have a definition of 'struct kinfo_proc' for calls to
kvm_getargv() & kvm_getenvv()

	
>How-To-Repeat:
	Write a program which calls kvm_getenvv() with only the include
files listed on the man page.
>Fix:
Add
	#include <sys/user.h>
to the man page.

	


>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->patched 
State-Changed-By: trhodes 
State-Changed-When: Sat Apr 26 08:01:15 PDT 2003 
State-Changed-Why:  
Switch this PR to me as I have just added sys/user.h to the list of includes, 
and will handle the MFC.  Thanks for pointing this out! 


Responsible-Changed-From-To: freebsd-doc->trhodes 
Responsible-Changed-By: trhodes 
Responsible-Changed-When: Sat Apr 26 08:01:15 PDT 2003 
Responsible-Changed-Why:  
Switch this PR to me as I have just added sys/user.h to the list of includes, 
and will handle the MFC.  Thanks for pointing this out! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=51322 
State-Changed-From-To: patched->closed 
State-Changed-By: trhodes 
State-Changed-When: Tue Apr 29 07:37:18 PDT 2003 
State-Changed-Why:  
MFC has taken place.  Thanks for the submission! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=51322 
>Unformatted:
