cavaliergopher / rpm

A Go implementation of the RPM file format
BSD 3-Clause "New" or "Revised" License
169 stars 44 forks source link

Fix header indexes length #12

Closed rpromyshlennikov closed 6 years ago

rpromyshlennikov commented 6 years ago

Replace logical incorrect check with "fool proofing" check.

Current check is logical incorrect because header length describes length of data section withOUT index section itself and we cannot statically check it at the point where this check is at the moment.

cavaliercoder commented 6 years ago

Excellent work, thank you. Upon revisiting this check, I see you are correct.

rpromyshlennikov commented 6 years ago

No problem, Ryan. You've created great library, what I glad to work with.