Closed Bug 972606 Opened 6 years ago Closed 6 years ago

Convert nsJAR::mManifestData to a modern hashtable

Categories

(Core :: Networking: JAR, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla30

People

(Reporter: mccr8, Assigned: mccr8)

References

Details

Attachments

(2 files, 1 obsolete file)

No description provided.
Assignee: nobody → continuation
Comment on attachment 8379776 [details] [diff] [review]
Convert nsJAR::mManifestData to nsClassHashtable.

Oops, I haven't actually done a try run for this yet.
Attachment #8379776 - Flags: review?(taras.mozilla)
Plus a few minor fixups in the header.
Attachment #8381515 - Flags: review?(aklotz)
Comment on attachment 8381514 [details] [diff] [review]
part 1 - Convert nsJAR::mManifestData to nsClassHashtable.

Review of attachment 8381514 [details] [diff] [review]:
-----------------------------------------------------------------

::: modules/libjar/nsJAR.cpp
@@ +651,5 @@
>                if (NS_FAILED(rv) || !exists)
>                  curItemMF->mType = JAR_INVALID;
>              }
>              //-- Check for duplicates
> +            if (mManifestData.Contains(curItemName))

Please add bracing around this if block.
Attachment #8381514 - Flags: review?(aklotz) → review+
Comment on attachment 8381515 [details] [diff] [review]
part 2 - Take advantage of infallible new in nsJAR.

Review of attachment 8381515 [details] [diff] [review]:
-----------------------------------------------------------------

::: modules/libjar/nsJAR.cpp
@@ +610,5 @@
>    const char* sectionStart = nextLineStart;
>  
>    nsJARManifestItem* curItemMF = nullptr;
>    bool foundName = false;
>    if (aFileType == JAR_MF)

Please add bracing around this if block.
Attachment #8381515 - Flags: review?(aklotz) → review+
Comment on attachment 8379776 [details] [diff] [review]
Convert nsJAR::mManifestData to nsClassHashtable.

L64 debug try run: https://tbpl.mozilla.org/?tree=Try&rev=ecd2e68bc23c
Attachment #8379776 - Attachment is obsolete: true
https://hg.mozilla.org/mozilla-central/rev/165e6579508a
https://hg.mozilla.org/mozilla-central/rev/4f7be2b146f5
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla30
You need to log in before you can comment on or make changes to this bug.