Closed
Bug 82981
Opened 24 years ago
Closed 23 years ago
nsComponentManagerUtils.h missing "#include <nsIFactory.h>"
Categories
(Core :: XPCOM, defect)
Core
XPCOM
Tracking
()
RESOLVED
INVALID
mozilla1.0
People
(Reporter: sam, Assigned: dougt)
References
Details
Attachments
(1 file)
(deleted),
patch
|
Details | Diff | Splinter Review |
Parameters of type "nsIFactory" are declared in nsComponentManagerUtils.h, but
nowhere are any files #included that define that type. Same for type
nsIComponentManger.
The problem can be fixed very simply by adding two lines near the top of the
file:
#include <nsIFactory.h>
#include <nsIComponentManager.h>
Reproducible: Always
Steps to Reproduce:
1. echo "#include <nsComponentManagerUtils.h>" > foo.cpp
2. c++ -I/mozilla/dist/include foo.cpp -o foo
Actual Results:
/sothis/projects1/mozilla/mozilla-0.8.1-debug-enabled/dist/include/nsComponentMa
nagerUtils.h:38: type specifier omitted for parameter
This may be related, but I think line 26 in the same file should be changed
from:
#ifndef OBSOLETE_MODULE_LOADING
to:
#ifdef OBSOLETE_MODULE_LOADING
since the code it wraps is the obsolete module loading code.
Reporter | ||
Comment 1•24 years ago
|
||
Updated•24 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 2•24 years ago
|
||
The patch posted removes those two lines, I believe. What is the problem caused
by the absence of the code described above?
Reporter | ||
Comment 3•24 years ago
|
||
Bugger! I got the patch ****-backwards.
Without those two headers included, nsIFactory and nsIComponentManager aren't
declared anywhere. They are used in nsComponentManagerUtils.h, so they need to
be declared.
I only see this problem compiling non-Mozilla code. In every case where it
counts, Mozilla code has obviously already included, directly or indirectly,
nsIFactory.h and nsIComponentManager.h before including
nsComponentManagerUtils.h. That's not the correct solution though.
Comment 4•23 years ago
|
||
I don't have an opinion on where these includes should be. But, do NOT checkin
#includes that use angle brakets for non system #includes. Use double quotes.
Angle brakets here would bust some platforms.
Assignee | ||
Updated•23 years ago
|
Target Milestone: --- → mozilla1.0
Assignee | ||
Updated•23 years ago
|
Keywords: mozilla1.0
Assignee | ||
Comment 6•23 years ago
|
||
I believe this to be invalid now after my component manager change.
Now, nsComponentManagerUtils.h include nsComponentManagerObsolete.h which
forward declares nsIFactory.
marking invalid
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → INVALID
You need to log in
before you can comment on or make changes to this bug.
Description
•