New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
archive/tar: TestSparseFile fails #21958
Comments
/CC @dsnet |
Can you do show me the contents of the For example, on mine:
(of course |
It looks like nothing special. |
The odd part is that I'm unable to reproduce this. I am on Darwin 16.4.0, but I'm hoping that doesn't make much of a difference. The problem is that my check in // Check for seekData/seekHole support.
if _, err := f.Seek(0, seekHole); errno(err) == syscall.EINVAL {
return nil, nil // Either old kernel or FS does not support this
} is clearly not triggering for some reason on your system. The man page on A part of me is tempted to catch
However, the source code for BSD tar just does a very liberal check where it assumes there is no support if any error is returned for @hirochachacha, can you test the following variation of the check on if _, err := f.Seek(0, seekHole); errno(err) == syscall.EINVAL || errno(err) == syscall.ENOTTY {
return nil, nil
} I'm leaning towards just treating any error as having no support, but I want to make sure I'm on the right track. |
Change https://golang.org/cl/65191 mentions this issue: |
It works fine! I remembered that my SSD is not made by apple, I replaced it before. |
Quite possibly, seems to match the statement:
Either way. Rather than playing whack-a-mole with every possible errno representing "not supported", I'm going to take the GNU and BSD tar approach and just consider any error as meaning "non supported". |
Fair enough. Thank you for your fix. |
Thank you for the bug report! |
Please answer these questions before submitting your issue. Thanks!
What did you do?
If possible, provide a recipe for reproducing the error.
A complete runnable program is good.
A link on play.golang.org is best.
./all.bash
What did you expect to see?
success
What did you see instead?
Does this issue reproduce with the latest release (go1.9)?
No
System details
It happens after 1eacf78
The text was updated successfully, but these errors were encountered: