gh-137396: Raise InvalidHeaderError when offset or numbytes is negative#137805
gh-137396: Raise InvalidHeaderError when offset or numbytes is negative#137805moreal wants to merge 1 commit into
Conversation
| @@ -0,0 +1,2 @@ | |||
| :func:`tarfile.Tarfile.fromtarfile` and :func:`tarfile.TarInfo.frombuf` raises | |||
There was a problem hiding this comment.
/home/runner/work/cpython/cpython/Doc/build/NEWS:191: WARNING: py:func reference target not found: tarfile.Tarfile.fromtarfile [ref.func]
See docs CI failure
There was a problem hiding this comment.
The reason why this fails is because fromtarfile is a classmethod of TarInfo not TarFile. Also, when referencing methods, it's better to use the meth role rather than the func one.
|
Can we put guards around all values that we expect to be positive or zero? I'm thinking:
|
One way to do it is to add a flag to |
|
This PR is stale because it has been open for 30 days with no activity. |
Uh oh!
There was an error while loading. Please reload this page.