Closed
Bug 703239
Opened 14 years ago
Closed 14 years ago
fix build Warnings in editor/
Categories
(Core :: DOM: Editor, defect)
Core
DOM: Editor
Tracking
()
RESOLVED
FIXED
mozilla12
People
(Reporter: atulagrwl, Assigned: atulagrwl)
Details
Attachments
(2 files, 2 obsolete files)
|
2.65 KB,
text/plain
|
Details | |
|
12.72 KB,
patch
|
Details | Diff | Splinter Review |
Patch coming shortly.
| Assignee | ||
Comment 1•14 years ago
|
||
Assignee: nobody → atulagrwl
Attachment #575141 -
Flags: review?(ehsan)
Comment 2•14 years ago
|
||
Comment on attachment 575141 [details] [diff] [review]
Patch v1
Review of attachment 575141 [details] [diff] [review]:
-----------------------------------------------------------------
This is great! r=me with the comments below.
::: editor/composer/src/nsComposerController.cpp
@@ +44,5 @@
>
> #define NS_REGISTER_ONE_COMMAND(_cmdClass, _cmdName) \
> { \
> _cmdClass* theCmd = new _cmdClass(); \
> + NS_ENSURE_TRUE(theCmd, NS_ERROR_OUT_OF_MEMORY); \
Now that you're here, can you please remove this NS_ENSURE_TRUE (and others below like it) too? operator new is infallible these days.
Thanks!
::: editor/libeditor/html/nsHTMLEditor.cpp
@@ +935,5 @@
> {
> if (!aNode)
> {
> NS_NOTREACHED("null node passed to GetBlockNodeParent()");
> + return nsnull;
Ouch!
::: editor/libeditor/html/nsHTMLEditorStyle.cpp
@@ +672,1 @@
> (!aProperty && NodeIsProperty(aNode))) // or node is any prop and we asked for that
Please remove the double parenthesis after if. Also, remove the trailing space after '(' on the first line.
Attachment #575141 -
Flags: review?(ehsan) → review+
| Assignee | ||
Comment 3•14 years ago
|
||
Attachment #575141 -
Attachment is obsolete: true
| Assignee | ||
Comment 4•14 years ago
|
||
(In reply to Ehsan Akhgari [:ehsan] from comment #2)
> Comment on attachment 575141 [details] [diff] [review] [diff] [details] [review]
> Patch v1
>
> Review of attachment 575141 [details] [diff] [review] [diff] [details] [review]:
> -----------------------------------------------------------------
>
> This is great! r=me with the comments below.
>
> ::: editor/composer/src/nsComposerController.cpp
> Now that you're here, can you please remove this NS_ENSURE_TRUE (and others
> below like it) too? operator new is infallible these days.
>
Done.
>
> ::: editor/libeditor/html/nsHTMLEditor.cpp
> @@ +935,5 @@
> > {
> > if (!aNode)
> > {
> > NS_NOTREACHED("null node passed to GetBlockNodeParent()");
> > + return nsnull;
>
> Ouch!
This was intentional. Did I miss something?
>
> ::: editor/libeditor/html/nsHTMLEditorStyle.cpp
> @@ +672,1 @@
> > (!aProperty && NodeIsProperty(aNode))) // or node is any prop and we asked for that
>
> Please remove the double parenthesis after if. Also, remove the trailing
> space after '(' on the first line.
Removed the trailing space but double parenthesis was intentional to shut compiler from throwing warnings.
Please review so that I can mark this bug checkin-needed.
Thanks !
| Assignee | ||
Updated•14 years ago
|
Attachment #577594 -
Flags: review?(ehsan)
Comment 5•14 years ago
|
||
Comment on attachment 577594 [details] [diff] [review]
Patch v1.10
The "ouch" was because we'd missed that case all this time! Great work, thanks a lot!
Attachment #577594 -
Flags: review?(ehsan) → review+
Comment 7•14 years ago
|
||
patching file editor/libeditor/html/nsHTMLEditor.cpp
Hunk #1 FAILED at 932
:(
Keywords: checkin-needed
| Assignee | ||
Comment 8•14 years ago
|
||
rebase on current code.
Attachment #577594 -
Attachment is obsolete: true
| Assignee | ||
Updated•14 years ago
|
Keywords: checkin-needed
Comment 9•14 years ago
|
||
Flags: in-testsuite-
Keywords: checkin-needed
OS: Linux → All
Hardware: x86_64 → All
Target Milestone: --- → mozilla12
Version: unspecified → Trunk
Comment 10•14 years ago
|
||
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•