From jdp@polstra.com  Fri Jul  7 16:05:21 1995
Received: from freebie.polstra.com (freebie.polstra.com [198.211.214.7])
          by freefall.cdrom.com (8.6.10/8.6.6) with ESMTP id QAA27695
          for <FreeBSD-gnats-submit@freebsd.org>; Fri, 7 Jul 1995 16:05:17 -0700
Received: (from jdp@localhost) by freebie.polstra.com (8.6.11/8.6.9) id QAA00998; Fri, 7 Jul 1995 16:06:40 -0700
Message-Id: <199507072306.QAA00998@freebie.polstra.com>
Date: Fri, 7 Jul 1995 16:06:40 -0700
From: jdp@polstra.com
Reply-To: jdp@polstra.com
To: FreeBSD-gnats-submit@freebsd.org
Cc: jdp@polstra.com
Subject: Bug + fix for pkg_add in 2.0.5-RELEASE
X-Send-Pr-Version: 3.2

>Number:         599
>Category:       bin
>Synopsis:       pkg_add does not stop if dependencies are missing
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    jkh
>State:          closed
>Quarter:
>Keywords:
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul  7 16:10:01 1995
>Closed-Date:    Sun Jun 2 21:36:33 PDT 1996
>Last-Modified:  Sun Jun  2 21:43:45 PDT 1996
>Originator:     John Polstra
>Release:        FreeBSD 2.0-BUILT-19950603 i386
>Organization:
Polstra & Co., Inc.
>Environment:

	FreeBSD 2.0.5-RELEASE, nothing unusual.

>Description:

	If pkg_add finds that some dependencies are missing, it reports
	them, but then it proceeds to try to install the package.  That
	results in a partial, non-working installation of the package.
	The manual page says that pkg_add should halt under these
	circumstances, unless the "-f" option has been supplied on the
	command line.

>How-To-Repeat:

	Run "pkg_add some-package" where "some-package" is any package
	that depends on one or more other packages which have not been
	installed on the system.

>Fix:
	

*** usr.sbin/pkg_install/add/perform.c-	Sat Jun 10 02:04:13 1995
--- usr.sbin/pkg_install/add/perform.c	Fri Jul  7 14:47:22 1995
***************
*** 256,261 ****
--- 256,265 ----
  		printf(" - already installed.\n");
  	}
  
+ 	/* Bomb off now, if we have found some missing dependencies */
+ 	if (code != 0)
+ 	    goto bomb;
+ 
  	/* If this is a direct extract and we didn't want it, stop now */
  	if (where_to != PlayPen && Fake)
  	    goto success;
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->jkh 
Responsible-Changed-By: pst 
Responsible-Changed-When: Wed Feb 7 17:41:18 PST 1996 
Responsible-Changed-Why:  
State-Changed-From-To: open->closed 
State-Changed-By: jkh 
State-Changed-When: Sun Jun 2 21:36:33 PDT 1996 
State-Changed-Why:  
Fix applied. 
>Unformatted:


