From ringworm01@gmail.com  Thu Mar  3 05:46:32 2005
Return-Path: <ringworm01@gmail.com>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id C766316A4CE
	for <FreeBSD-gnats-submit@freebsd.org>; Thu,  3 Mar 2005 05:46:32 +0000 (GMT)
Received: from vms042pub.verizon.net (vms042pub.verizon.net [206.46.252.42])
	by mx1.FreeBSD.org (Postfix) with ESMTP id 6744643D49
	for <FreeBSD-gnats-submit@freebsd.org>; Thu,  3 Mar 2005 05:46:32 +0000 (GMT)
	(envelope-from ringworm01@gmail.com)
Received: from ringworm.mechee.com ([4.27.46.32])
 by vms042.mailsrvcs.net (Sun Java System Messaging Server 6.2 HotFix 0.04
 (built Dec 24 2004)) with ESMTPA id <0ICR00CKQHDGFOS0@vms042.mailsrvcs.net> for
 FreeBSD-gnats-submit@freebsd.org; Wed, 02 Mar 2005 23:46:30 -0600 (CST)
Received: by ringworm.mechee.com (Postfix, from userid 1001)
	id 55EFF2CE7D2; Wed, 02 Mar 2005 21:46:27 -0800 (PST)
Message-Id: <20050303054627.55EFF2CE7D2@ringworm.mechee.com>
Date: Wed, 02 Mar 2005 21:46:27 -0800 (PST)
From: ringworm01@gmail.com
Reply-To: Michael C.Shultz <ringworm01@gmail.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: [MAINTAINER] sysutils/portmanager update to 0.2.9_1
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         78341
>Category:       ports
>Synopsis:       [MAINTAINER] sysutils/portmanager update to 0.2.9_1
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    flz
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Thu Mar 03 05:50:14 GMT 2005
>Closed-Date:    Thu Mar 03 08:52:15 GMT 2005
>Last-Modified:  Thu Mar 03 08:52:15 GMT 2005
>Originator:     Michael C. Shultz
>Release:        FreeBSD 5.4-PRERELEASE i386
>Organization:
>Environment:
System: FreeBSD ringworm.mechee.com 5.4-PRERELEASE FreeBSD 5.4-PRERELEASE #0: Thu Feb 24 05:35:32 PST 2005 root@ringworm.mechee.com:/ROUTER/obj/usr/src/sys/RINGWORM i386


>Description:

sysutils/portmanager update to 0.2.9_1

note to commiter:  please add files/patch-0.2.9_1

1) Added an informative error if portmanager is not run as root.

>How-To-Repeat:

	N/A

>Fix:

--- portmanager-0.2.9_1.diff begins here ---
diff -ruN portmanager/Makefile portmanager-0.2.9_1/Makefile
--- portmanager/Makefile	Tue Mar  1 00:47:15 2005
+++ portmanager-0.2.9_1/Makefile	Wed Mar  2 16:13:53 2005
@@ -7,7 +7,7 @@
 
 PORTNAME=	portmanager
 PORTVERSION=	0.2.9
-PORTREVISION=	0
+PORTREVISION=	1
 #-----------------------------------------
 #for local use, remove before submitting PR
 CATEGORIES=		sysutils
diff -ruN portmanager/files/patch-0.2.9_1 portmanager-0.2.9_1/files/patch-0.2.9_1
--- portmanager/files/patch-0.2.9_1	Wed Dec 31 16:00:00 1969
+++ portmanager-0.2.9_1/files/patch-0.2.9_1	Wed Mar  2 16:13:23 2005
@@ -0,0 +1,68 @@
+diff -ruN --exclude=Makefile.in --exclude=externVars.h.in --exclude=config.h.in --exclude=config.h.in~ ./NEWS ../../0.2.9_1/portmanager/NEWS
+--- ./NEWS	Sun Feb 27 13:51:55 2005
++++ ../../0.2.9_1/portmanager/NEWS	Wed Mar  2 15:31:42 2005
+@@ -2,6 +2,10 @@
+ 
+ NOTE to self: Monitor from 0.2.1 to 0.2.2 item 3.
+ 
++from 0.2.9 to 0.2.9_1	(March 2005)
++
++	1) Added warnings if portmanager is not run as root
++
+ from 0.2.8 to 0.2.9	(February 2005)
+ 
+ 	1) Fixed %done reporting in xterm title bar
+diff -ruN --exclude=Makefile.in --exclude=externVars.h.in --exclude=config.h.in --exclude=config.h.in~ ./libMG/src/MGdbCreate.c ../../0.2.9_1/portmanager/libMG/src/MGdbCreate.c
+--- ./libMG/src/MGdbCreate.c	Thu Feb 17 21:55:04 2005
++++ ../../0.2.9_1/portmanager/libMG/src/MGdbCreate.c	Wed Mar  2 15:34:11 2005
+@@ -68,7 +68,7 @@
+ 	{
+ 		fprintf(stderr, "%s ERROR: unable to open %s\n", id, db->parent.path);
+ 		perror("error");
+-		assert(0);
++		return( NULL );
+ 	}
+ 
+ 	/*zzzzzzzzzzzzzz*/
+diff -ruN --exclude=Makefile.in --exclude=externVars.h.in --exclude=config.h.in --exclude=config.h.in~ ./libPMGR/src/PMGRrDbCreate.c ../../0.2.9_1/portmanager/libPMGR/src/PMGRrDbCreate.c
+--- ./libPMGR/src/PMGRrDbCreate.c	Thu Feb 17 09:39:55 2005
++++ ../../0.2.9_1/portmanager/libPMGR/src/PMGRrDbCreate.c	Wed Mar  2 15:38:33 2005
+@@ -78,6 +78,12 @@
+ 						NULL);
+ 	/*zzzzzzzzzzzzzz*/
+ 
++	if( !property->installedPortsDb )
++	{
++		fprintf( stderr, "%s %s error: portmanager must be run as root\n", id, VERSION );
++		exit(1);
++	}
++
+ 	/*zzzzzzzzzzzzzz*/
+ 	property->objIdx++;
+ 	property->dependencyPortsDb	= MGdbCreate( 
+diff -ruN --exclude=Makefile.in --exclude=externVars.h.in --exclude=config.h.in --exclude=config.h.in~ ./libPMGR/src/PMGRrInitialize.c ../../0.2.9_1/portmanager/libPMGR/src/PMGRrInitialize.c
+--- ./libPMGR/src/PMGRrInitialize.c	Thu Feb 17 22:55:53 2005
++++ ../../0.2.9_1/portmanager/libPMGR/src/PMGRrInitialize.c	Wed Mar  2 15:55:57 2005
+@@ -38,6 +38,7 @@
+ 
+ int	PMGRrInitialize( structProperty* property, int argc, char** argv )
+ {
++	char	id[]		= "PMGRrInitialize";
+ 	char*	commandLineKey	= NULL;
+ 	int	errorCode	= 0;
+ 	int	idx		= 0;	
+@@ -164,6 +165,14 @@
+ 	*/
+ 	property->commandLineDb	= MGdbCreate( property->commandLineDbFileName, property->fieldCommandLineKey, 
+ 					property->fieldCommandLineValue, NULL ); 
++
++	if( !property->commandLineDb )
++	{
++		fprintf( stderr, "%s %s error: portmanager must be run as root\n", id, VERSION );
++		exit(1);
++	}
++
++
+ 	idx	= 1;
+ 	while( idx < argc )
+ 	{
--- portmanager-0.2.9_1.diff ends here ---


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports-bugs->flz 
Responsible-Changed-By: flz 
Responsible-Changed-When: Thu Mar 3 06:04:45 GMT 2005 
Responsible-Changed-Why:  
Grab. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=78341 
State-Changed-From-To: open->closed 
State-Changed-By: flz 
State-Changed-When: Thu Mar 3 08:52:05 GMT 2005 
State-Changed-Why:  
Committed, thanks! 

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