Closed Bug 789827 Opened 14 years ago Closed 14 years ago

Fix nullptr abuse in comm-central

Categories

(MailNews Core :: Backend, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 18.0

People

(Reporter: rain1, Assigned: rain1)

References

Details

Attachments

(1 file)

Attached patch patch v1 — — Splinter Review
comm-central uses nullptr in areas where it shouldn't be used. This fixes those cases.
Attachment #659594 - Flags: review?(mbanner)
>- tmp = '%'; *end = nullptr; >+ tmp = '%'; *end = NULL; > } > else if (end-1 > start && *(end-1) == '%') > { >- end -= 1; tmp = '%'; *end = nullptr; >+ end -= 1; tmp = '%'; *end = NULL; > } > else if (end-2 > start && *(end-2) == '%') > { >- end -= 2; tmp = '%'; *end = nullptr; >+ end -= 2; tmp = '%'; *end = NULL; > } > else > { >- tmp = *end; *end = nullptr; >+ tmp = *end; *end = NULL; |*end = 0;| or |*end = '\0';|. *end is not a pointer.
Comment on attachment 659594 [details] [diff] [review] patch v1 r=me with the change of END -> 0 for the "*end = " cases. I'll land this in a moment as the tree is busted with this.
Attachment #659594 - Flags: review?(mbanner) → review+
Target Milestone: --- → Thunderbird 18.0
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: