HomeFreeBSD

Overhaul of 'ar' support:
rS168740Unpublished

Unpublished Commit ยท Learn More

No further details are available.

Description

Overhaul of 'ar' support:

  • use "AR_GNU" as the format name instead of AR_SVR4 (it's what everyone is going to call it anyway)
  • Simplify numeric parsing to unsigned (none of the numeric values should ever be negative); don't run off end of numeric fields.
  • Finish parsing the common header fields before the next I/O request (which might dump the contents)
  • Be smarter about format guessing and trimming filenames.
  • Most of the magic values are only used in one place, so just inline them.
  • Many more comments.
  • Be smarter about handling damaged entries; return something reasonable.
  • Call it a "filename table" instead of a "string table"
  • Update tests.

Enable selection of 'ar', 'arbsd', and 'argnu' formats by name
(this allows bsdtar to create ar format archives).

The 'ar' writer still needs some work; it should reject
entries that aren't regular files and should probably also
strip leading paths from filenames.

Details

Provenance
kientzleAuthored on
Parents
rS168739: Invoke utime(2) properly. (It's only used on platforms
Branches
Unknown
Tags
Unknown

Event Timeline