Closed
Bug 332045
Opened 18 years ago
Closed 18 years ago
toolkit/components/gnome should use the glue
Categories
(Toolkit Graveyard :: Build Config, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: benjamin, Assigned: benjamin)
References
Details
Attachments
(1 file)
7.89 KB,
patch
|
darin.moz
:
first-review+
|
Details | Diff | Splinter Review |
toolkit/components/gnome should use the frozen string API and the glue
Assignee | ||
Comment 1•18 years ago
|
||
Attachment #216591 -
Flags: first-review?(darin)
Comment 2•18 years ago
|
||
Comment on attachment 216591 [details] [diff] [review] Build components/gnome against the glue, rev. 1 >Index: toolkit/components/gnome/nsGConfService.cpp >+ nsCAutoString key(NS_LITERAL_CSTRING("/desktop/gnome/url-handlers/")); >+ key.Append(aScheme); >+ key.Append(NS_LITERAL_CSTRING("/command")); Personally, I'd just drop the NS_LITERAL_CSTRING calls here. The savings of not having to compute string lengths is probably not significant compared to the cost of initializing and finalizing nsCStringContainer objects. Same goes for elsewhere. >Index: toolkit/components/gnome/nsGnomeVFSService.cpp ... > NS_IMETHODIMP > nsGnomeVFSMimeApp::GetSupportedURISchemes(nsIUTF8StringEnumerator** aSchemes) > { > *aSchemes = nsnull; > >+ nsRefPtr<UTF8StringEnumerator> array = new UTF8StringEnumerator(); > NS_ENSURE_TRUE(array, NS_ERROR_OUT_OF_MEMORY); > > for (GList *list = mApp->supported_uri_schemes; list; list = list->next) { >+ if (!array->mStrings.AppendElement(nsDependentCString((char*) list->data))) { Did you try compiling this without the nsDependentCString(...) bit? I think it should work because nsCString has a constructor that takes a |const char *|. The nsDependentCString doesn't do anything to avoid a string copy. >+ nsCAutoString fileExtToUse(NS_LITERAL_CSTRING(".")); >+ fileExtToUse.Append(aExtension); Again, NS_LITERAL_CSTRING could be dropped here. r=darin
Attachment #216591 -
Flags: first-review?(darin) → first-review+
Assignee | ||
Comment 3•18 years ago
|
||
Fixed on trunk.
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 5•18 years ago
|
||
Really fixed on trunk.
Status: REOPENED → RESOLVED
Closed: 18 years ago → 18 years ago
Resolution: --- → FIXED
Updated•6 years ago
|
Product: Toolkit → Toolkit Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•