Closed Bug 562539 Opened 15 years ago Closed 15 years ago

deprecated conversion from string constant to char* in nsHttpTransaction::ParseHead

Categories

(Core :: Networking: HTTP, defect)

defect
Not set
minor

Tracking

()

RESOLVED FIXED
mozilla1.9.3a5

People

(Reporter: timeless, Assigned: timeless)

Details

Attachments

(1 file, 3 obsolete files)

In member function ‘nsresult nsHttpTransaction::ParseHead nsHttpTransaction.cpp:783: warning: deprecated conversion from string constant to ‘char*’
Attached patch patch (obsolete) — Splinter Review
Assignee: nobody → timeless
Status: NEW → ASSIGNED
Attachment #442286 - Flags: review?(cbiesinger)
Comment on attachment 442286 [details] [diff] [review] patch Patch is empty?
Attachment #442286 - Flags: review?(cbiesinger) → review-
Attached patch with patch (obsolete) — Splinter Review
Attachment #442286 - Attachment is obsolete: true
Attachment #442345 - Flags: review?(jduell.mcbugs)
Comment on attachment 442345 [details] [diff] [review] with patch >- mResponseHead->ParseStatusLine(""); >+ mResponseHead->ParseStatusLine(nsnull); Any reason why you want to pass null in, instead of just making ParseStatusLine take a const char *? The latter seems safer to me: I haven't gone through all the logic, but it seems like it could be easy to blow up with null ptr ref if we pass 0. The code compiles at least with a "const char *" signature for ParseStatusLine.
Attached patch change prototypes (obsolete) — Splinter Review
i read through the code and confirmed that the nspr strcmp function is happy enough about null pointers. but yeah, i'm fine changing the signatures instead.
Attachment #442345 - Attachment is obsolete: true
Attachment #442484 - Flags: review?
Attachment #442345 - Flags: review?(jduell.mcbugs)
Attachment #442484 - Flags: review? → review?(jduell.mcbugs)
Comment on attachment 442484 [details] [diff] [review] change prototypes please limit your lines to 80 characters
Comment on attachment 442484 [details] [diff] [review] change prototypes Break the lines so they're less than 80 chars (sorry about advising you differenly on IRC :), and this is +r from me.
Attachment #442484 - Flags: review?(jduell.mcbugs) → review+
Attachment #442484 - Attachment is obsolete: true
Attachment #442953 - Flags: review+
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a5
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: