From nobody@FreeBSD.org  Fri Jun 22 15:43:21 2007
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52])
	by hub.freebsd.org (Postfix) with ESMTP id D60C316A421
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 22 Jun 2007 15:43:21 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [69.147.83.33])
	by mx1.freebsd.org (Postfix) with ESMTP id C9CE713C46A
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 22 Jun 2007 15:43:21 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.13.1/8.13.1) with ESMTP id l5MFhLGe018473
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 22 Jun 2007 15:43:21 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.13.1/8.13.1/Submit) id l5MFhLBd018472;
	Fri, 22 Jun 2007 15:43:21 GMT
	(envelope-from nobody)
Message-Id: <200706221543.l5MFhLBd018472@www.freebsd.org>
Date: Fri, 22 Jun 2007 15:43:21 GMT
From: Gary Stanley <gary@velocity-servers.net>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [PATCH] Add poll() to qstat
X-Send-Pr-Version: www-3.0

>Number:         113948
>Category:       ports
>Synopsis:       [PATCH] Add poll() to qstat
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    danfe
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jun 22 15:50:08 GMT 2007
>Closed-Date:    Sun Jun 24 15:29:42 GMT 2007
>Last-Modified:  Sun Jun 24 15:29:42 GMT 2007
>Originator:     Gary Stanley
>Release:        
>Organization:
>Environment:
FreeBSD granite.eroded.org 6.2-RELEASE FreeBSD 6.2-RELEASE #0: Fri Jan 12 11:05:30 UTC 2007     root@dessler.cse.buffalo.edu:/usr/obj/usr/src/sys/SMP  i386
>Description:
In qstat.c, we check for USE_POLL, OpenBSD is defined and FreeBSD should be defined as well. This adds poll() support to qstat. 

Patch is tested and works.

before; 
 90741 qstat    CALL  select(0x4,0x807abc0,0,0,0xbfbfea88)
 90741 qstat    RET   select 1

after;
 93117 qstat    CALL  poll(0x8080200,0x1,0x3e8)
 93117 qstat    RET   poll 1


>How-To-Repeat:

>Fix:


Patch attached with submission follows:

--- qstat.c.orig        Sat Oct 22 05:20:07 2005
+++ qstat.c     Fri Jun 22 09:57:21 2007
@@ -120,6 +120,10 @@
 #define USE_POLL
 #include <sys/poll.h>
 #endif
+#ifdef __FreeBSD__
+#define USE_POLL
+#include <sys/poll.h>
+#endif
 #ifdef __OpenBSD__
 #define USE_POLL
 #include <sys/poll.h>

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->danfe 
Responsible-Changed-By: miwi 
Responsible-Changed-When: Sun Jun 24 11:09:08 UTC 2007 
Responsible-Changed-Why:  
Over to maintainer. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=113948 
State-Changed-From-To: open->closed 
State-Changed-By: danfe 
State-Changed-When: Sun Jun 24 15:28:46 UTC 2007 
State-Changed-Why:  
Committed (inplace editing instead of a patch), thanks! 

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