From nobody  Sun Feb  2 03:26:14 1997
Received: (from nobody@localhost)
          by freefall.freebsd.org (8.8.5/8.8.5) id DAA14267;
          Sun, 2 Feb 1997 03:26:14 -0800 (PST)
Message-Id: <199702021126.DAA14267@freefall.freebsd.org>
Date: Sun, 2 Feb 1997 03:26:14 -0800 (PST)
From: zorac@mbox.kyoto-inet.or.jp
To: freebsd-gnats-submit@freebsd.org
Subject: tar dumped core with -g option.
X-Send-Pr-Version: www-1.0

>Number:         2637
>Category:       gnu
>Synopsis:       tar dumped core with -g option.
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Feb  2 03:30:01 PST 1997
>Closed-Date:    Sun Jun 17 04:11:57 PDT 2001
>Last-Modified:  Sun Jun 17 04:14:51 PDT 2001
>Originator:     Hiroya Tsubakimoto
>Release:        2.1.6.1
>Organization:
4000Do Co.,LTD.
>Environment:
FreeBSD s2.c4000do.co.kyoto-inet.or.jp 2.1.6.1-RELEASE FreeBSD 2.1.6.1-RELEASE #3: Sat Dec  7 06:22:
42 JST 1996     zorac@s2.c4000do.co.kyoto-inet.or.jp:/usr/src/sys/compile/HOME  i386

>Description:
tar dumped core when it has -g option and add a sub-directory has KANJI name.

>How-To-Repeat:
linke this:

bash$ ls -a . dir
.:
.       ..      dir

dir:
.                       ..                      ????????????????           <-- KANJI name
bash$ ./tar -c -g ./log -f ./x dir
bash$ cat ./log
854881844
1036 25994 dir/\.77\.67\.44\.67\.44\.44\.16\/14\.16\.53\.16\/31\.16\/00\.16\/36
bash$ ./tar -c -g ./log -f ./x dir
Segmentation fault (core dumped)

>Fix:
following patch:

*** port.c      Tue May 30 14:04:44 1995
--- port.c.patch        Thu Nov  7 19:53:55 1996
***************
*** 889,895 ****
            *to_there++ = '?';
          else
            {
!             to_there[0] = (c >> 6) + '0';
              to_there[1] = ((c >> 3) & 07) + '0';
              to_there[2] = (c & 07) + '0';
              to_there += 3;
--- 889,895 ----
            *to_there++ = '?';
          else
            {
!             to_there[0] = ((c >> 6) & 03) + '0';
              to_there[1] = ((c >> 3) & 07) + '0';
              to_there[2] = (c & 07) + '0';
              to_there += 3;

>Release-Note:
>Audit-Trail:

From: "Pedro F. Giffuni" <giffunip@asme.org>
To: freebsd-gnats-submit@freebsd.org, zorac@mbox.kyoto-inet.or.jp
Cc:  Subject: Re: gnu/2637: tar dumped core with -g option.
Date: Fri, 06 Mar 1998 11:49:54 -0500

 FWIW, OpenBSD claims they made lots of fixes to both the updated GNU tar
 and pax. It would be a good idea to check them out.
State-Changed-From-To: open->closed 
State-Changed-By: schweikh 
State-Changed-When: Sun Jun 17 04:11:57 PDT 2001 
State-Changed-Why:  
It seems the log file format has changed since. It no longer 
includes the '1036 25994 dir/...' part with the bogus octal 
numbers, only the epoch timestamp is there. 

http://www.FreeBSD.org/cgi/query-pr.cgi?pr=2637 
>Unformatted:
