Closed Bug 414148 Opened 12 years ago Closed 12 years ago

Avoid copy of some nsDependentC?Strings

Categories

(Core :: General, defect)

defect
Not set

Tracking

()

RESOLVED FIXED

People

(Reporter: jag+mozilla, Assigned: jag+mozilla)

Details

(Keywords: perf)

Attachments

(1 file, 1 obsolete file)

 
The summary says it all.
Status: NEW → ASSIGNED
Summary: Prefer |const nsDependentC?String&| over → Prefer |const nsDependentC?String&| over |nsDependentC?String|
Attachment #299450 - Flags: superreview?
Attachment #299450 - Flags: superreview? → superreview?(dbaron)
Comment on attachment 299450 [details] [diff] [review]
Switch some dependent strings over to const&s

>Index: widget/src/gtk2/nsClipboard.cpp
>-    nsDependentCString htmlStr =
>+    const nsDependentCString& htmlStr =
>         nsDependentCString((const char *)data, dataLength);

This should be just:

const nsDependentCString htmlStr((const char*)data, dataLength);
Attachment #299450 - Flags: superreview?(dbaron) → superreview+
Ah yes. Forest, trees.
Attachment #299450 - Attachment is obsolete: true
Attachment #299454 - Flags: superreview+
Attachment #299454 - Flags: approval1.9?
Attachment #299454 - Flags: approval1.9? → approval1.9+
Checking in layout/xul/base/src/nsTextBoxFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/nsTextBoxFrame.cpp,v  <--  nsTextBoxFrame.cpp
new revision: 1.129; previous revision: 1.128
done
Checking in layout/xul/base/src/tree/src/nsTreeBodyFrame.cpp;
/cvsroot/mozilla/layout/xul/base/src/tree/src/nsTreeBodyFrame.cpp,v  <--  nsTreeBodyFrame.cpp
new revision: 1.347; previous revision: 1.346
done
Checking in widget/src/gtk2/nsClipboard.cpp;
/cvsroot/mozilla/widget/src/gtk2/nsClipboard.cpp,v  <--  nsClipboard.cpp
new revision: 1.31; previous revision: 1.30
done
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Summary: Prefer |const nsDependentC?String&| over |nsDependentC?String| → Avoid copy of some nsDependentC?Strings
Keywords: perf
You need to log in before you can comment on or make changes to this bug.