bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-tar] file name with backslash is not archived


From: Paul Eggert
Subject: Re: [Bug-tar] file name with backslash is not archived
Date: Sun, 31 Oct 2010 00:11:42 -0700
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.12) Gecko/20101027 Thunderbird/3.1.6

Thanks.  As you wrote, that trace output says this:

lstat64("/home/dinar/\320\224\320\276\320\272\321\203\320\274\320\265\320\275\321\202\321\213/SED:
 How can I replace a newline (\n)? - Stack Overflow.html", 0xbf91b3ac) = -1 
ENOENT (No such file or directory)

Is there actually a file by that name in your directory?  That is,
suppose you compile and run the following C program.  What happens?
(Try running it with "strace", e.g., "strace ./a.out".)  If it fails
just like tar does, then I don't see the bug in tar: the problem would
be that you've passed the wrong name to tar.  If it succeeds but tar
fails, then we need to do more investigation to see what the tar bug
really is.


#include <stdio.h>
#include <sys/stat.h>

char const file_name[] =
  "/home/dinar/\320\224\320\276\320\272\321\203\320\274\320\265\320\275"
  "\321\202\321\213/SED: "
  "How can I replace a newline (\n)? - Stack Overflow.html";

int
main (void)
{
  struct stat st;
  if (lstat (file_name, &st) != 0)
    {
      perror (file_name);
      return 1;
    }
  return 0;
}




reply via email to

[Prev in Thread] Current Thread [Next in Thread]