|Subject:||[Bug-tar] tar append/open problem & code fix|
|Date:||Thu, 23 Feb 2012 15:31:31 -0700|
|User-agent:||Mozilla/5.0 (Windows NT 6.1; rv:10.0.1) Gecko/20120208 Thunderbird/10.0.1|
Say one has a tar file called
test.tar and wants to append some newfile
But what if one accidentally
types (note the extra '/' in front of the tar file name) and they
don't have '/' permissions?
What gets incorrectly
I tracked down the source of the problem in the 1.26 code and
made a fix to my local version to verify the correct results
The problem is in
buffer.c line 753 after the call to rmtopen.
statement on that line is called despite the archive file
descriptor being negative.
L753 switch( check_compressed_archive (NULL) )
The simple fix is to add an 'if' statement prior to the switch as so:
archive = rmtopen( archive_name_array,
Hope that helps.
|[Prev in Thread]||Current Thread||[Next in Thread]|