Bug 32902

Summary: Incremental tar archiving using GNU style fails to handle regional chars
Product: Base System Reporter: Martin P. Hansen <mph>
Component: gnuAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 4.1.1-RELEASE   
Hardware: Any   
OS: Any   

Description Martin P. Hansen 2001-12-16 15:30:01 UTC
tar's '-g' option doesn't handle regional chars properly, it archives wheter or not the file is modified.

Fix: 

This all happens due a missing increment in un_quote_string() in port.c.

At line 992 "*to_there = tmp;" should be "*to_there++ = tmp;".
How-To-Repeat: Creating a test tree containing two directories one without extended chars and one with. Put two or more docs in each and try to tar:
tar -g snapshot -cvf test.tar test-tree/
and then
tar -g snapshot -cvf test2.tar test-tree/

The second tar should ofcause not archive anything except some dirs. But will faithfully archive the complete dir with the regional char.
Comment 1 Sheldon Hearn 2001-12-30 13:26:33 UTC
On Sun, 16 Dec 2001 07:20:57 PST, "Martin P. Hansen" wrote:

> >Category:       gnu
> >Synopsis:       Incremental tar archiving using GNU style fails to handle regional chars

I've asked on the freebsd-audit mailing list for someone to take a look
at this.

Ciao,
Sheldon.
Comment 2 Johan Karlsson freebsd_committer freebsd_triage 2002-08-22 18:29:11 UTC
State Changed
From-To: open->closed

Tar has been upgraded to 1.13.25, which does not 
have this particular file and there is no 
variable named 'to_there' either.