mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-01 11:27:55 +00:00
fix 29333 make the initial construction passing "" for performance and legal nsString usage. r=rickg a=bobj
This commit is contained in:
parent
982af48162
commit
485fcaf806
@ -682,7 +682,7 @@ char* nsString::ToNewCString() const {
|
||||
* http://www.cis.ohio-state.edu/htbin/rfc/rfc2279.html
|
||||
*/
|
||||
char* nsString::ToNewUTF8String() const {
|
||||
nsCString temp(*this);
|
||||
nsCString temp("");
|
||||
temp.SetCapacity(8); //ensure that we get an allocated buffer instead of the common empty one.
|
||||
|
||||
// Caculate how many bytes we need
|
||||
|
@ -682,7 +682,7 @@ char* nsString::ToNewCString() const {
|
||||
* http://www.cis.ohio-state.edu/htbin/rfc/rfc2279.html
|
||||
*/
|
||||
char* nsString::ToNewUTF8String() const {
|
||||
nsCString temp(*this);
|
||||
nsCString temp("");
|
||||
temp.SetCapacity(8); //ensure that we get an allocated buffer instead of the common empty one.
|
||||
|
||||
// Caculate how many bytes we need
|
||||
|
@ -682,7 +682,7 @@ char* nsString::ToNewCString() const {
|
||||
* http://www.cis.ohio-state.edu/htbin/rfc/rfc2279.html
|
||||
*/
|
||||
char* nsString::ToNewUTF8String() const {
|
||||
nsCString temp(*this);
|
||||
nsCString temp("");
|
||||
temp.SetCapacity(8); //ensure that we get an allocated buffer instead of the common empty one.
|
||||
|
||||
// Caculate how many bytes we need
|
||||
|
Loading…
x
Reference in New Issue
Block a user