Closed Bug 620367 Opened 15 years ago Closed 15 years ago

Fix unused variable warning in InsertVisitedURI::AddVisit

Categories

(Toolkit :: Places, defect)

x86
Linux
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla2.0b9

People

(Reporter: Ms2ger, Assigned: Ms2ger)

References

Details

(Whiteboard: [build_warning])

Attachments

(1 file, 3 obsolete files)

Attached patch Patch v1 (obsolete) — Splinter Review
Since bug 599969, collision has been unused in opt builds.
Flags: in-testsuite-
Attachment #498724 - Flags: review?(sdwilsh)
personally I think it would be better to do bool visited = Fetch... if (!visited) { NS_NOT_REACHED() }
hum, the assertion looks strange though. it should ensure that visited is true... This worries me.
(In reply to comment #2) > hum, the assertion looks strange though. it should ensure that visited is > true... This worries me. No, it's fine; we just added it to moz_places, so we should not have a visit at this point.
Comment on attachment 498724 [details] [diff] [review] Patch v1 I prefer the approach in comment 2. r=sdwilsh with a patch like that.
Attachment #498724 - Flags: review?(sdwilsh) → review+
(In reply to comment #3) > (In reply to comment #2) > > hum, the assertion looks strange though. it should ensure that visited is > > true... This worries me. > No, it's fine; we just added it to moz_places, so we should not have a visit at > this point. well, then the comment is nonsense // Now that it should be in the database, we need to obtain the id of the // visit we just added. update it so it says "we need to obtain the id of the page we just added" and not the visit.
(In reply to comment #5) > well, then the comment is nonsense er, right, the comment is bogus. s/visit/place/
Attached patch Patch v2 (obsolete) — Splinter Review
Thanks!
Attachment #498724 - Attachment is obsolete: true
Attachment #498745 - Flags: approval2.0?
Comment on attachment 498745 [details] [diff] [review] Patch v2 ehr, sorry you inherited my typo, the right one is NS_NOTREACHED (no underscore before reached)
Attachment #498745 - Flags: review-
and should be if (visited) due to comment 3 (we must follow what the assertion was doing)
Attached patch Patch v3 (obsolete) — Splinter Review
Right, sorry.
Attachment #498745 - Attachment is obsolete: true
Attachment #498759 - Flags: approval2.0?
Attachment #498745 - Flags: approval2.0?
Attachment #498759 - Flags: approval2.0? → approval2.0+
Attachment #498759 - Attachment is obsolete: true
Keywords: checkin-needed
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla2.0b9
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: