From nobody@FreeBSD.org  Wed Apr 30 04:37:43 2008
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 3DA0C1065676
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 30 Apr 2008 04:37:43 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 31AEA8FC15
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 30 Apr 2008 04:37:43 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.2/8.14.2) with ESMTP id m3U4b4s3091471
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 30 Apr 2008 04:37:04 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.2/8.14.1/Submit) id m3U4b49V091470;
	Wed, 30 Apr 2008 04:37:04 GMT
	(envelope-from nobody)
Message-Id: <200804300437.m3U4b49V091470@www.freebsd.org>
Date: Wed, 30 Apr 2008 04:37:04 GMT
From: Hitoshi Matsunawa <matsunaw@ja2.so-net.ne.jp>
To: freebsd-gnats-submit@FreeBSD.org
Subject: incompatibility of bsdtar and ctm
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         123246
>Category:       bin
>Synopsis:       incompatibility of bsdtar(1) and ctm
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    kientzle
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Apr 30 04:40:01 UTC 2008
>Closed-Date:    Wed Aug 13 06:04:38 UTC 2008
>Last-Modified:  Wed Aug 13 06:04:38 UTC 2008
>Originator:     Hitoshi Matsunawa
>Release:        FreeBSD 7.0-RELEASE i386
>Organization:
none
>Environment:
FreeBSD 7.0-RELEASE #0: Sun Feb 24 19:59:52 UTC 2008 root@logan.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC
>Description:
following log explain a problem well:
----------
% ctm -u -V2 -B 1 /usr/local/src/z/src-7/src-7.0*
Working on </usr/local/src/z/src-7/src-7.0171.gz>
Expecting Global MD5 <51427c7a341c6663f4f66e7b2c60baa1>
Reference Global MD5 <51427c7a341c6663f4f66e7b2c60baa1>
tar: no files or directories specified
% 
----------

if i placed a ``4.11's tar binary'' somewhere before /usr/bin in my $path, ctm done without error.

>How-To-Repeat:
use ctm with -B option.

>Fix:
n/a

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->kientzle 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Wed Apr 30 05:38:07 UTC 2008 
Responsible-Changed-Why:  
Tim, can you take a look at this one? 

http://www.freebsd.org/cgi/query-pr.cgi?pr=123246 

From: Jaakko Heinonen <jh@saunalahti.fi>
To: matsunaw@ja2.so-net.ne.jp
Cc: bug-followup@FreeBSD.org
Subject: Re: bin/123246: incompatibility of bsdtar(1) and ctm
Date: Wed, 30 Apr 2008 10:50:15 +0300

 --pf9I7BMVVzbSWLtt
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 
 
 Hi,
 
 I think that this is a bug in bsdtar(1). It doesn't allow -r and -T
 together if no files are given on command line.
 
 Attached patch (against RELENG_7) may help.
 
 -- 
 Jaakko
 
 --pf9I7BMVVzbSWLtt
 Content-Type: text/x-diff; charset=us-ascii
 Content-Disposition: attachment; filename="bsdtar--r-names_from_file.diff"
 
 Index: write.c
 ===================================================================
 RCS file: /home/ncvs/src/usr.bin/tar/write.c,v
 retrieving revision 1.63
 diff -p -u -r1.63 write.c
 --- write.c	29 May 2007 05:39:10 -0000	1.63
 +++ write.c	30 Apr 2008 07:09:28 -0000
 @@ -1531,7 +1531,7 @@ test_for_append(struct bsdtar *bsdtar)
  {
  	struct stat s;
  
 -	if (*bsdtar->argv == NULL)
 +	if (*bsdtar->argv == NULL && bsdtar->names_from_file == NULL)
  		bsdtar_errc(bsdtar, 1, 0, "no files or directories specified");
  	if (bsdtar->filename == NULL)
  		bsdtar_errc(bsdtar, 1, 0, "Cannot append to stdout.");
 
 --pf9I7BMVVzbSWLtt--

From: Jaakko Heinonen <jh@saunalahti.fi>
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/123246: incompatibility of bsdtar(1) and ctm
Date: Thu, 1 May 2008 12:51:08 +0300

 Submitter confirmed in private mail that the patch fixes the problem for
 him.

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/123246: commit references a PR
Date: Fri,  2 May 2008 05:15:10 +0000 (UTC)

 kientzle    2008-05-02 05:14:58 UTC
 
   FreeBSD src repository
 
   Modified files:
     usr.bin/tar          write.c 
   Log:
   Allow -r with -T even if there are no files on the command line.
   
   PR: bin/123246
   MFC after: 3 days
   
   Revision  Changes    Path
   1.66      +1 -1      src/usr.bin/tar/write.c
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 

From: Tim Kientzle <kientzle@freebsd.org>
To: Jaakko Heinonen <jh@saunalahti.fi>
Cc: bug-followup@freebsd.org
Subject: Re: bin/123246: incompatibility of bsdtar(1) and ctm
Date: Thu, 01 May 2008 22:22:18 -0700

 I've committed Jaakko's fix to -CURRENT.
 
 > From: Jaakko Heinonen <jh@saunalahti.fi>
 > To: matsunaw@ja2.so-net.ne.jp
 > Cc: bug-followup@FreeBSD.org
 > Subject: Re: bin/123246: incompatibility of bsdtar(1) and ctm
 > Date: Wed, 30 Apr 2008 10:50:15 +0300
 >  
 >  Hi,
 >  
 >  I think that this is a bug in bsdtar(1). It doesn't allow -r and -T
 >  together if no files are given on command line.
 >  
 >  Attached patch (against RELENG_7) may help.
 >  
 >  
 >  Index: write.c
 >  ===================================================================
 >  RCS file: /home/ncvs/src/usr.bin/tar/write.c,v
 >  retrieving revision 1.63
 >  diff -p -u -r1.63 write.c
 >  --- write.c	29 May 2007 05:39:10 -0000	1.63
 >  +++ write.c	30 Apr 2008 07:09:28 -0000
 >  @@ -1531,7 +1531,7 @@ test_for_append(struct bsdtar *bsdtar)
 >   {
 >   	struct stat s;
 >   
 >  -	if (*bsdtar->argv == NULL)
 >  +	if (*bsdtar->argv == NULL && bsdtar->names_from_file == NULL)
 >   		bsdtar_errc(bsdtar, 1, 0, "no files or directories specified");
 >   	if (bsdtar->filename == NULL)
 >   		bsdtar_errc(bsdtar, 1, 0, "Cannot append to stdout.");
 
State-Changed-From-To: open->patched 
State-Changed-By: gavin 
State-Changed-When: Wed Jun 11 12:53:41 UTC 2008 
State-Changed-Why:  
Mark as patched, this is fixed in HEAD but has not yet been MFC'd 

http://www.freebsd.org/cgi/query-pr.cgi?pr=123246 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/123246: commit references a PR
Date: Sun, 10 Aug 2008 06:45:10 +0000 (UTC)

 kientzle    2008-08-10 06:44:39 UTC
 
   FreeBSD src repository
 
   Modified files:        (Branch: RELENG_7)
     usr.bin/tar          write.c 
   Log:
   SVN rev 181506 on 2008-08-10 06:44:39Z by kientzle
   
   MFC r178714: allow -r and -T together even when there are no files on
   the command line.
   
   PR:             bin/123246
   
   Revision  Changes    Path
   1.63.2.3  +1 -1      src/usr.bin/tar/write.c
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/123246: commit references a PR
Date: Wed, 13 Aug 2008 05:37:21 +0000 (UTC)

 kientzle    2008-08-13 05:36:49 UTC
 
   FreeBSD src repository
 
   Modified files:        (Branch: RELENG_6)
     usr.bin/tar          write.c 
   Log:
   SVN rev 181674 on 2008-08-13 05:36:49Z by kientzle
   
   MFC r178714: Allow -r with -T when there are no files on the command line
   
   PR:             bin/123246
   
   Revision   Changes    Path
   1.41.2.15  +1 -1      src/usr.bin/tar/write.c
 _______________________________________________
 cvs-all@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/cvs-all
 To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
 
State-Changed-From-To: patched->closed 
State-Changed-By: kientzle 
State-Changed-When: Wed Aug 13 06:03:59 UTC 2008 
State-Changed-Why:  
Fixed in -CURRENT, 7-STABLE, and 6-STABLE 

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