Closed
Bug 337731
Opened 20 years ago
Closed 19 years ago
Make gnomefvs use frozen linkage
Categories
(Core :: Networking: File, defect)
Tracking
()
RESOLVED
FIXED
mozilla1.9alpha1
People
(Reporter: benjamin, Assigned: benjamin)
References
Details
Attachments
(2 files, 1 obsolete file)
|
13.76 KB,
patch
|
darin.moz
:
review+
|
Details | Diff | Splinter Review |
|
6.63 KB,
patch
|
darin.moz
:
review+
|
Details | Diff | Splinter Review |
Because it uses runtime resolution of the optional gnomevfs libraries, it cannot be part of libxul.
| Assignee | ||
Comment 1•20 years ago
|
||
Attachment #222698 -
Flags: review?(darin)
Comment 2•20 years ago
|
||
Comment on attachment 222698 [details] [diff] [review]
Frozen linkage for gnomevfs, rev. 1
>Index: extensions/gnomevfs/nsGnomeVFSProtocolHandler.cpp
>+ nsAutoString dispHost = NS_ConvertUTF8toUTF16(scheme);
NS_ConvertUTF8toUTF16 dispHost(scheme);
>+ mDirBuf.Append(NS_LITERAL_CSTRING("300: "));
Avoid calling NS_LITERAL_CSTRING since it just adds code bloat.
What we really need is AppendLiteral, but in place of that I'd
just call Append("300: ") since that is going to be less code
and plenty efficient.
>+ if (mSpec.get()[mSpec.Length() - 1] != '/')
Hmm... we should define CharAt or maybe even operator[] :-)
>+static void
>+StripWhitespace(nsCString& aString)
>+{
This should be moved into nsStringAPI, no? At least it should
make use of the APIs you added there. Perhaps nsStringAPI.h
should have a .Strip method?
>- PRInt32 colon = spec.FindChar(':');
>- if (colon == kNotFound)
>+ const char *specstring = aSpec.get();
nit: specString or specStr
r=darin
Attachment #222698 -
Flags: review?(darin) → review+
| Assignee | ||
Comment 3•20 years ago
|
||
Ok, this implements the StripChars and StripWhitespace signatures on the external nsAString/nsACString, and unit-tests them.
Comment 4•19 years ago
|
||
Comment on attachment 222797 [details] [diff] [review]
astring.StripChars(), rev. 1
What if BeginWriting fails on |this|?
| Assignee | ||
Comment 5•19 years ago
|
||
BeginWriting can fail? Ugh
| Assignee | ||
Comment 6•19 years ago
|
||
Attachment #222797 -
Attachment is obsolete: true
Attachment #222854 -
Flags: review?(darin)
Updated•19 years ago
|
Attachment #222854 -
Flags: review?(darin) → review+
| Assignee | ||
Comment 7•19 years ago
|
||
I landed this on trunk on 2006-05-23
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•