Recent fixes to nsChromeRegistry.cpp cause HP builds to fail

CLOSED FIXED

Status

P3
blocker
CLOSED FIXED
19 years ago
3 months ago

People

(Reporter: pepper, Assigned: pavlov)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

19 years ago
Changes made over the weekend have broken the HP builds.  I've been trying for
several days to track down the problem with little success.  I have also
had Waqar take a look.


The error is:

Error 280: "nsChromeRegistry.cpp", line 476 # Operator & expects lvalue
    operand.
      void *data = mDataSourceTable->Get(&nsStringKey(overlayFile));
                                                      ^^^^^^^^^^^
Error 280: "nsChromeRegistry.cpp", line 566 # Operator & expects lvalue
    operand.
        mDataSourceTable->Put(&nsStringKey(aFileName), (void*)supports.get());
                                           ^^^^^^^^^
Error 280: "nsChromeRegistry.cpp", line 590 # Operator & expects lvalue
    operand.
          void *data = mDataSourceTable->Get(&nsStringKey(chromeFile));
                                                          ^^^^^^^^^^
make[3]: *** [nsChromeRegistry.o] Error 2
make[3]: Leaving directory `/builds/pepper/Lizard/bld/mozilla/rdf/chrome/src'

I understand that the address operator is expecting an lvalue but I can't figure
out why its rejecting the one being passed in.  This seems to be working for the
tier-1 platforms.  It may be an ANSI compliance issue or a quirk in the aCC
compiler, I dunno for sure.  Here is an excerpt from the cpp file that sets
overlayFile:

..........
..........
  nsCAutoString overlayFile;

  // Retrieve the mInner data source.
  overlayFile = "resource:/chrome/";
  overlayFile += package;
  overlayFile += provider; // provider already has a / in the front of it
  overlayFile += "/";
  overlayFile += "overlays.rdf";

  void *data = mDataSourceTable->Get(&nsStringKey(overlayFile));
<------Generates the first error
  if (data)
  {
    nsCOMPtr<nsIRDFDataSource> dataSource;
    nsISupports *supports = NS_STATIC_CAST(nsISupports*, data);
    dataSource = do_QueryInterface(supports, &rv);
........
........

From this I believe that overlayFile is in fact being set to a valid lvalue.  I
see absolutely nothing wrong with the above code.

Updated

19 years ago
Assignee: waterson → pavlov

Comment 1

19 years ago
heh heh...
(Assignee)

Updated

19 years ago
Status: NEW → RESOLVED
Last Resolved: 19 years ago
Resolution: --- → FIXED
(Assignee)

Comment 2

19 years ago
checked in fix

Comment 3

19 years ago
old bug - closing
Status: RESOLVED → CLOSED

Updated

3 months ago
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.