Closed Bug 362462 Opened 18 years ago Closed 16 years ago

GCC 4.3 Changes make Firefox fail to initialize.

Categories

(Firefox Build System :: General, defect)

x86
Linux
defect
Not set
major

Tracking

(Not tracked)

RESOLVED WORKSFORME

People

(Reporter: kentfredric, Unassigned)

Details

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (X11; U; Linux i686; en-GB; rv:1.8.1) Gecko/20061201 BonEcho/2.0
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-GB; rv:1.8.1) Gecko/20061201 BonEcho/2.0

When compiled against GCC4.3, firefox simply hangs on inititialization, and sits there and burns processor time in an idle loop. ( 

Im no code genius, but recently GCC made a change to the way "extern inline" works. While I cant see myself this being in firefox's code, its easily the culprit.

Reproducible: Always

Steps to Reproduce:
1. Compile Firefox with GCC-4.3 ( gentoo-portage's 4.3.0_alpha20061111 )
2. Run firefox
3. See Failure
4. Switch compiler back to 4.1 
5. Compile firefox
6. See firefox run.


Actual Results:  
 $ firefox
/usr/lib/mozilla-firefox/mozilla-xremote-client: Error: Failed to find a running server.
/usr/lib/mozilla-firefox/mozilla-xremote-client: Error: Failed to find a running server.
No running windows found
fcntl(F_SETLK) failed. errno = 11
No Persistent Registry Found.
Type Manifest File: /usr/lib/mozilla-firefox/components/xpti.dat
###!!! ASSERTION: Failed to write xpti manifest!: 'Error', file xptiInterfaceInfoManager.cpp, line 1937
Break: at file xptiInterfaceInfoManager.cpp, line 1937
*** Registering Apprunner components (all right -- a generic module!)
nsNativeComponentLoader: autoregistering begins.
*** Registering nsSystemPrefModule components (all right -- a generic module!)
*** Registering docshell_provider components (all right -- a generic module!)
*** Registering mozStorageModule components (all right -- a generic module!)
*** Registering JavaScript_Debugger components (all right -- a generic module!)
*** Registering nsToolkitCompsModule components (all right -- a generic module!)
*** Registering application components (all right -- a generic module!)
*** Registering xpconnect components (all right -- a generic module!)
*** Registering xpconnect_test components (all right -- a generic module!)
*** Registering necko_core_and_primary_protocols components (all right -- a generic module!)
*** Registering nsCJVMManagerModule components (all right -- a generic module!)
*** Registering nsLayoutModule components (all right -- a generic module!)
*** Registering nsChromeModule components (all right -- a generic module!)
*** Registering nsRDFModule components (all right -- a generic module!)
*** Registering nsSampleModule components (all right -- a generic module!)
*** Registering nsTypeAheadFindSea components (all right -- a generic module!)
*** Registering nsMorkModule components (all right -- a generic module!)
*** Registering nsUCvMathModule components (all right -- a generic module!)
*** Registering nsIconDecoderModule components (all right -- a generic module!)
*** Registering nsUConvModule components (all right -- a generic module!)
*** Registering nsJarModule components (all right -- a generic module!)
*** Registering Browser_Embedding_Module components (all right -- a generic module!)
*** Registering nsAutoConfigModule components (all right -- a generic module!)
*** Registering necko_secondary_protocols components (all right -- a generic module!)
*** Registering nsGfxPSModule components (all right -- a generic module!)
*** Registering nsPluginModule components (all right -- a generic module!)
*** Registering nsComposerModule components (all right -- a generic module!)
*** Registering BrowserDirProvider components (all right -- a generic module!)
*** Registering CommandLineModule components (all right -- a generic module!)
*** Registering BOOT components (all right -- a generic module!)
*** Registering nsWidgetGtk2Module components (all right -- a generic module!)
*** Registering nsFindComponent components (all right -- a generic module!)
*** Registering embedcomponents components (all right -- a generic module!)
*** Registering RemoteServiceModule components (all right -- a generic module!)
*** Registering mozMySpellModule components (all right -- a generic module!)
*** Registering MyService components (all right -- a generic module!)
*** Registering nsTestDynamicModule components (all right -- a generic module!)
*** Registering nsWebServicesModule components (all right -- a generic module!)
*** Registering nsPermissionsModule components (all right -- a generic module!)
*** Registering nsAuthModule components (all right -- a generic module!)
*** Registering nsSecurityManagerModule components (all right -- a generic module!)
*** Registering mozgnome components (all right -- a generic module!)
*** Registering TransformiixModule components (all right -- a generic module!)
*** Registering nsGfxGTKModule components (all right -- a generic module!)
*** Registering nsUniversalCharDetModule components (all right -- a generic module!)
*** Registering nsEditorModule components (all right -- a generic module!)
*** Registering nsPrefModule components (all right -- a generic module!)
*** Registering nsTransactionManagerModule components (all right -- a generic module!)
*** Registering mozSpellCheckerModule components (all right -- a generic module!)
*** Registering xpctools components (all right -- a generic module!)
*** Registering nsI18nModule components (all right -- a generic module!)
*** Registering nsXMLExtrasModule components (all right -- a generic module!)
*** Registering nsImageLib2Module components (all right -- a generic module!)
*** Registering nsFileViewModule components (all right -- a generic module!)
*** Registering nsBrowserCompsModule components (all right -- a generic module!)
*** Registering xpcomObsoleteModule components (all right -- a generic module!)
*** Registering SearchServiceModule components (all right -- a generic module!)
*** Registering nsCookieModule components (all right -- a generic module!)
*** Registering WSPProxyTestModule components (all right -- a generic module!)
*** Registering nsGnomeVFSModule components (all right -- a generic module!)
*** Registering nsParserModule components (all right -- a generic module!)
*** Registering appshell components (all right -- a generic module!)
*** Registering schemavalidation components (all right -- a generic module!)
*** Registering NSS components (all right -- a generic module!)
*** Registering nsAccessibilityModule components (all right -- a generic module!)
*** Registering PKI components (all right -- a generic module!)
*** Registering nsSoftwareUpdate components (all right -- a generic module!)
*** Registering nsGfxXprintModule components (all right -- a generic module!)
nsNativeComponentLoader: autoregistering succeeded
###!!! ASSERTION: Failed to write xpti manifest!: 'Error', file xptiInterfaceInfoManager.cpp, line 1937
Break: at file xptiInterfaceInfoManager.cpp, line 1937
*** Deferring registration of sample JS components
*** Registering -venkman handler.
*** Registering x-jsd protocol handler.
*** Registering x-application-jsd content handler.
nsNativeComponentLoader: registering deferred (0)
*** Registering sample JS components
nsNativeComponentLoader: registering deferred (0)
nsNativeComponentLoader: registering deferred (0)
nsNativeComponentLoader: registering deferred (0)
+++ JavaScript debugging hooks installed.
nsNativeComponentLoader: autoregistering begins.
nsNativeComponentLoader: autoregistering succeeded
###!!! ASSERTION: Failed to write xpti manifest!: 'Error', file xptiInterfaceInfoManager.cpp, line 1937
Break: at file xptiInterfaceInfoManager.cpp, line 1937
nsNativeComponentLoader: registering deferred (0)
pldhash: for the table at address 0x83f1900, the given entrySize of 44 probably favors chaining over double hashing.
###!!! ASSERTION: bad urlType: 'Not Reached', file nsStandardURL.cpp, line 2524
Break: at file nsStandardURL.cpp, line 2524
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsResProtocolHandler.cpp, line 147
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsResProtocolHandler.cpp, line 167
###!!! ASSERTION: Not a nsIFileURL!: 'manifestFileURL', file nsChromeRegistry.cpp, line 1120
Break: at file nsChromeRegistry.cpp, line 1120
###!!! ASSERTION: You can't dereference a NULL nsCOMPtr with operator->().: 'mRawPtr != 0', file ../../dist/include/xpcom/nsCOMPtr.h, line 849
Break: at file ../../dist/include/xpcom/nsCOMPtr.h, line 849
Program /usr/lib/mozilla-firefox/firefox-bin (pid = 31879) received signal 11.
Stack:
UNKNOWN [/usr/lib/mozilla-firefox/components/libchrome.so +0x00009D84]
UNKNOWN [/usr/lib/mozilla-firefox/components/libchrome.so +0x0000408E]
UNKNOWN [/usr/lib/mozilla-firefox/libxpcom_core.so +0x0002C21E]
UNKNOWN [/usr/lib/mozilla-firefox/libxpcom_core.so +0x000881F6]
UNKNOWN [/usr/lib/mozilla-firefox/libxpcom_core.so +0x0008A8C1]
CallGetService(char const*, nsID const&, void**)+0x00000039 [/usr/lib/mozilla-firefox/libxpcom_core.so +0x000287F9]
nsGetServiceByContractID::operator()(nsID const&, void**) const+0x0000002B [/usr/lib/mozilla-firefox/libxpcom_core.so +0x0002889B]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x0000D440]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x0000D488]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x0000532F]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x00006117]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x0000775E]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x000084C1]
UNKNOWN [/usr/lib/mozilla-firefox/firefox-bin +0x000033CF]
__libc_start_main+0x000000DC [/lib/libc.so.6 +0x0001583C]
Sleeping for 300 seconds.
Type 'gdb /usr/lib/mozilla-firefox/firefox-bin 31879' to attach your debugger to this thread.

## backtrace from GDB
#0  0xb7f16410 in __kernel_vsyscall ()
#1  0x410a72b6 in __nanosleep_nocancel () from /lib/libc.so.6
#2  0x410a70cb in __sleep (seconds=0) at ../sysdeps/unix/sysv/linux/sleep.c:138
#3  0x08061baa in ah_crap_handler (signum=11) at nsSigHandlers.cpp:133
#4  <signal handler called>
#5  0xb722d777 in nsChromeRegistry::CheckForNewChrome (this=0x83f18e0) at nsChromeRegistry.cpp:1123
#6  0xb722ad84 in nsChromeRegistry::Init (this=0x83f18e0) at nsChromeRegistry.cpp:553
#7  0xb722508e in nsChromeRegistryConstructor (aOuter=0x0, aIID=@0x8064710, aResult=0xbfaebbd4) at nsChromeFactory.cpp:50
#8  0xb7d3721e in nsGenericFactory::CreateInstance (this=0x83f1f30, aOuter=0x0, aIID=@0x8064710, aResult=0xbfaebbd4) at nsGenericFactory.cpp:79
#9  0xb7d931f6 in nsComponentManagerImpl::CreateInstanceByContractID (this=0x80990b8, aContractID=0x8063bc0 "@mozilla.org/chrome/chrome-registry;1", aDelegate=0x0,
    aIID=@0x8064710, aResult=0xbfaebbd4) at nsComponentManager.cpp:1981
#10 0xb7d958c1 in nsComponentManagerImpl::GetServiceByContractID (this=0x80990b8, aContractID=0x8063bc0 "@mozilla.org/chrome/chrome-registry;1", aIID=@0x8064710,
    result=0xbfaebc50) at nsComponentManager.cpp:2408
#11 0xb7d337f9 in CallGetService (aContractID=0x8063bc0 "@mozilla.org/chrome/chrome-registry;1", aIID=@0x8064710, aResult=0xbfaebc50) at nsComponentManagerUtils.cpp:94
#12 0xb7d3389b in nsGetServiceByContractID::operator() (this=<value optimized out>, aIID=@0x411400bc, aInstancePtr=0x0) at nsComponentManagerUtils.cpp:278
#13 0x08055440 in nsCOMPtr<nsIToolkitChromeRegistry>::assign_from_gs_contractid (this=0xbfaebccc, gs={mContractID = 0x8063bc0 "@mozilla.org/chrome/chrome-registry;1"},
    aIID=@0x8064710) at ../../dist/include/xpcom/nsCOMPtr.h:1272
#14 0x08055488 in nsCOMPtr (this=0xbfaebccc, gs={mContractID = 0x8063bc0 "@mozilla.org/chrome/chrome-registry;1"}) at ../../dist/include/xpcom/nsCOMPtr.h:677
#15 0x0804d32f in ScopedXPCOMStartup::SetWindowCreator (this=0xbfaebe68, native=0x806f948) at nsAppRunner.cpp:729
#16 0x0804e117 in ProfileLockedDialog (aProfileDir=0x8088708, aProfileLocalDir=0x8088708, aUnlocker=0x0, aNative=0x806f948, aResult=0xbfaec2f4) at nsAppRunner.cpp:1252
#17 0x0804f75e in SelectProfile (aResult=0xbfaec2f4, aNative=0x806f948, aStartOffline=<value optimized out>) at nsAppRunner.cpp:1643
#18 0x080504c1 in XRE_main (argc=<value optimized out>, argv=0xbfaec3e4, aAppData=0x8067ca0) at nsAppRunner.cpp:2164
#19 0x0804b3cf in main (argc=Cannot access memory at address 0x0) at nsBrowserApp.cpp:61
#20 0x4103383c in __libc_start_main (main=0x804b390 <main>, argc=1, ubp_av=0xbfaec3e4, init=0x8062f50 <__libc_csu_init>, fini=0x8062f40 <__libc_csu_fini>,rtld_fini=0x4100dec0 <_dl_fini>, stack_end=0xbfaec3dc) at libc-start.c:238
#21 0x0804b321 in _start ()





Expected Results:  
No running windows found
Type Manifest File: /home/kdetester/.mozilla/firefox/6kwgsih1.default/xpti.dat
+++ JavaScript debugging hooks installed.
*** Registering Apprunner components (all right -- a generic module!)
nsNativeComponentLoader: autoregistering begins.
nsNativeComponentLoader: autoregistering succeeded
nsNativeComponentLoader: registering deferred (0)
pldhash: for the table at address 0x811d358, the given entrySize of 44 probably favors chaining over double hashing.
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsChromeRegistry.cpp, line 1561
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsChromeRegistry.cpp, line 1561
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsChromeRegistry.cpp, line 1561
GFX: dpi=96 t2p=0.0666667 p2t=15 depth=24
++WEBSHELL == 1
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsPermissionManager.cpp, line 632
++DOMWINDOW == 1
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
++DOMWINDOW == 2
++WEBSHELL == 2
++DOMWINDOW == 3
++DOMWINDOW == 4
Note: styleverifytree is disabled
Note: frameverifytree is disabled
Note: verifyreflow is disabled
++WEBSHELL == 3
++DOMWINDOW == 5
++DOMWINDOW == 6
++DOMWINDOW == 7
LoadPlugin() /opt/netscape/plugins/libflashplayer.so returned 8aaee40
GetMIMEDescription() returned "application/x-shockwave-flash:swf:Shockwave Flash;application/futuresplash:spl:FutureSplash Player"
LoadPlugin() /usr/lib/mozilla-firefox/plugins/libnullplugin.so returned 8aafdd8
GetMIMEDescription() returned ""
LoadPlugin() /usr/lib/mozilla-firefox/plugins/libunixprintplugin.so returned 8ab2ca8
GetMIMEDescription() returned ""
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsStringBundle.cpp, line 273
--DOMWINDOW == 6
WARNING: requested removal of nonexistent window
 #### firefox spawns here somewhere and then i kill it ####
, file nsWindowWatcher.cpp, line 1108
--WEBSHELL == 2
WARNING: cannot post event if not initialized, file nsHttpConnectionMgr.cpp, line 167
--WEBSHELL == 1
--WEBSHELL == 0
WARNING: WriteDataCacheBlocks() failed., file nsDiskCacheStreams.cpp, line 523
nsPluginHostImpl::Observe "xpcom-shutdown"
--DOMWINDOW == 5
--DOMWINDOW == 4
--DOMWINDOW == 3
--DOMWINDOW == 2
WARNING: nsExceptionService ignoring thread destruction after shutdown, file nsExceptionService.cpp, line 191
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsGlobalHistory.cpp, line 2611
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(OpenDB())) failed, file nsGlobalHistory.cpp, line 1260
--DOMWINDOW == 1
--DOMWINDOW == 0
+++ JavaScript debugging hooks removed.
###!!! ASSERTION: oops: '!mBufDirty', file nsDiskCacheStreams.cpp, line 456
Break: at file nsDiskCacheStreams.cpp, line 456
###!!! ASSERTION: deleting dirty buffer: 'mBufDirty == PR_FALSE', file nsDiskCacheStreams.cpp, line 757
Break: at file nsDiskCacheStreams.cpp, line 757
nsPluginHostImpl dtor
GC Cache:
        hits:  696  173   69   19   34    7   62    5    6    3
        hits: 1074, misses: 269, hit percent: 79.970216%
nsStringStats
 => mAllocCount:          15882
 => mReallocCount:         3853
 => mFreeCount:           15880  --  LEAKED 2 !!!
 => mShareCount:          15827
 => mAdoptCount:           2105
 => mAdoptFreeCount:       2072  --  LEAKED 33 !!!


###########BuildConfig from working compile:##############
Build tools
Compiler 	Version 	Compiler flags
i686-pc-linux-gnu-gcc 	gcc version 4.1.1 (Gentoo 4.1.1-r1) 	-Wall -W -Wno-unused -Wpointer-arith -Wcast-align -Wno-long-long -march=i686 -mtune=athlon-xp -pipe -ggdb -Wno-return-type -w -pthread -pipe
i686-pc-linux-gnu-g++ 	gcc version 4.1.1 (Gentoo 4.1.1-r1) 	-fno-rtti -fno-handle-exceptions -Wall -Wconversion -Wpointer-arith -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-non-virtual-dtor -Wno-long-long -march=i686 -mtune=athlon-xp -pipe -ggdb -Wno-return-type -w -fshort-wchar -pthread -pipe -DARON_WAS_HERE

Configure arguments
--enable-application=browser --enable-optimize=-O2 --disable-installer --disable-pedantic --enable-crypto --with-system-jpeg --with-system-png --with-system-zlib --disable-updater --enable-default-toolkit=gtk2 --enable-pango --enable-svg --enable-svg-renderer=cairo --enable-system-cairo --disable-strip --disable-strip-libs --enable-single-profile --disable-profilesharing --disable-profilelocking --enable-ipv6 --enable-xinerama --enable-xprint --disable-freetype2 --enable-debug --enable-tests --disable-reorder --enable-debugger-info-modules=ALL_MODULES --enable-application=browser --enable-image-encoder=all --enable-canvas --with-system-nspr --with-system-nss --enable-oji --enable-mathml --enable-jsd --enable-xpctools --with-default-mozilla-five-home=/usr/lib/mozilla-firefox --enable-extensions=default,xforms,schema-validation,typeaheadfind,venkman --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --build=i686-pc-linux-gnu

###########################
######GCC-4.3 INFOS#########
i686-pc-linux-gnu-gcc -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with: /tmp/..var/portage/sys-devel/gcc-4.3.0_alpha20061111/work/gcc-4.3-20061111/configure --prefix=/usr --bindir=/usr/i686-pc-linux-gnu/gcc-bin/4.3.0-alpha20061111 --includedir=/usr/lib/gcc/i686-pc-linux-gnu/4.3.0-alpha20061111/include --datadir=/usr/share/gcc-data/i686-pc-linux-gnu/4.3.0-alpha20061111 --mandir=/usr/share/gcc-data/i686-pc-linux-gnu/4.3.0-alpha20061111/man --infodir=/usr/share/gcc-data/i686-pc-linux-gnu/4.3.0-alpha20061111/info --with-gxx-include-dir=/usr/lib/gcc/i686-pc-linux-gnu/4.3.0-alpha20061111/include/g++-v4 --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --disable-altivec --enable-nls --without-included-gettext --with-system-zlib --disable-checking --disable-werror --disable-libunwind-exceptions --disable-multilib --enable-libmudflap --disable-libssp --enable-java-awt=gtk --enable-objc-gc --enable-languages=c,c++,java,objc,obj-c++,fortran --enable-shared --enable-threads=posix --enable-bootstrap --enable-__cxa_atexit --enable-clocale=gnu
Thread model: posix
gcc version 4.3.0-alpha20061111  (experimental) (Gentoo 4.3.0_alpha20061111)
hm... how do you know that "extern inline" is the cause of this bug?
I actually had the crash appear in GCC4.2 candidates... I traced it back to "manifestFileURL" being a nsSimpleURI instead of a nsStandardURL. I traced it back to an error in nsIOService::NewURI but I forget what was the cause.
Status: UNCONFIRMED → NEW
Ever confirmed: true
The problem is annoying and makes all mozilla packages unusable (firefox, thunderbird, xulrunner) when building with gcc 4.2 20070214 (4.2 which is now default on some development lines of Linux distributions).
gcc 4.2, thunderbird 2.0b2
[arekm@tarm ~]$ mozilla-thunderbird  --debug
/usr/lib/mozilla-thunderbird/run-mozilla.sh -g /usr/lib/mozilla-thunderbird/thunderbird-bin
MOZILLA_FIVE_HOME=/usr/lib/mozilla-thunderbird
  LD_LIBRARY_PATH=/usr/lib/mozilla-thunderbird:/usr/lib/mozilla-thunderbird/plugins:/usr/lib/mre/mre-2.0b2
DISPLAY=:0
DYLD_LIBRARY_PATH=/usr/lib/mozilla-thunderbird:/usr/lib/mre/mre-2.0b2
     LIBRARY_PATH=/usr/lib/mozilla-thunderbird:/usr/lib/mozilla-thunderbird/components:/usr/lib/mre/mre-2.0b2
       SHLIB_PATH=/usr/lib/mozilla-thunderbird:/usr/lib/mre/mre-2.0b2
          LIBPATH=/usr/lib/mozilla-thunderbird:/usr/lib/mre/mre-2.0b2
       ADDON_PATH=/usr/lib/mozilla-thunderbird
      MOZ_PROGRAM=/usr/lib/mozilla-thunderbird/thunderbird-bin
      MOZ_TOOLKIT=
        moz_debug=1
     moz_debugger=
which: no ddd in (/home/users/arekm/.vpython/bin:/sbin:/usr/sbin:/usr/local/sbin:/home/users/arekm/bin:/home/users/arekm/.vpython/bin:/sbin:/usr/sbin:/usr/local/sbin:/home/users/arekm/bin:/usr/local/bin:/bin:/usr/bin:/usr/X11R6/bin:/home/users/arekm/bin)
/usr/bin/gdb /usr/lib/mozilla-thunderbird/thunderbird-bin -x /tmp/mozargs.r7Tfnz
GNU gdb 6.6.50.20070102
Copyright (C) 2007 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "i686-pld-linux"...
Using host libthread_db library "/lib/libthread_db.so.1".
(gdb) r
Starting program: /usr/lib/mozilla-thunderbird/thunderbird-bin
Type Manifest File: /home/users/arekm/.thunderbird/i2mxqx4h.default/xpti.dat
*** Registering Apprunner components (all right -- a generic module!)
nsNativeComponentLoader: autoregistering begins.
nsNativeComponentLoader: autoregistering succeeded
nsNativeComponentLoader: registering deferred (0)
pldhash: for the table at address 0x80e3128, the given entrySize of 44 probably favors chaining over double hashing.
###!!! ASSERTION: bad urlType: 'Not Reached', file nsStandardURL.cpp, line 2524
Break: at file nsStandardURL.cpp, line 2524
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsResProtocolHandler.cpp, line 147
WARNING: NS_ENSURE_TRUE(NS_SUCCEEDED(rv)) failed, file nsResProtocolHandler.cpp, line 167
###!!! ASSERTION: Not a nsIFileURL!: 'manifestFileURL', file nsChromeRegistry.cpp, line 1120
Break: at file nsChromeRegistry.cpp, line 1120
###!!! ASSERTION: You can't dereference a NULL nsCOMPtr with operator->().: 'mRawPtr != 0', file ../../dist/include/xpcom/nsCOMPtr.h, line 849
Break: at file ../../dist/include/xpcom/nsCOMPtr.h, line 849

Program received signal SIGSEGV, Segmentation fault.
0xb690ac31 in nsChromeRegistry::CheckForNewChrome (this=0x80e3108) at nsChromeRegistry.cpp:1123
1123      manifestFileURL->GetFile(getter_AddRefs(manifest));
(gdb) print manifestFileURL
$1 = {
  mRawPtr = 0x0
}
(gdb) print manifest
$2 = {
  mRawPtr = 0x0
}
(gdb)                                  

hm,
(gdb) b nsIOService::NewURI
Can't find member of namespace, class, struct, or union named "nsIOService::NewURI"
Isn't urlType **** here? (see backtrace below)

Forcing urlType to some proper value makes thunderbird compiled with gcc 4.2 start.
No idea about mozilla code details... trying to find out why urlType is set to ****.

NS_IMETHODIMP
nsStandardURL::Init(PRUint32 urlType,
                    PRInt32 defaultPort,
                    const nsACString &spec,
                    const char *charset,
                    nsIURI *baseURI)
{
    ENSURE_MUTABLE();

    InvalidateCache();

    // XXX hack
+    urlType = URLTYPE_STANDARD;

    switch (urlType) {
    case URLTYPE_STANDARD:
        mParser = net_GetStdURLParser();
        break;
    case URLTYPE_AUTHORITY:



Breakpoint 2 at 0xb680ebee: file nsStandardURL.cpp, line 2511.
Pending breakpoint "nsStandardURL.cpp:2511" resolved

Breakpoint 2, nsStandardURL::Init (this=0x80eb580, urlType=3214650369, defaultPort=-1, spec=@0xbf9bacc0, charset=0x0, baseURI=0x0) at nsStandardURL.cpp:2511
2511        InvalidateCache();
(gdb) print urlType
$1 = 3214650369
(gdb) bt
#0  nsStandardURL::Init (this=0x80eb580, urlType=3214650369, defaultPort=-1, spec=@0xbf9bacc0, charset=0x0, baseURI=0x0) at nsStandardURL.cpp:2511
#1  0xb680f04d in nsStandardURL::SetFile (this=0x80eb580, file=0x80eb410) at nsStandardURL.cpp:2476
#2  0xb686c4dd in nsFileProtocolHandler::NewFileURI (this=0x80eb550, file=0x80eb410, result=0xbf9badc8) at nsFileProtocolHandler.cpp:295
#3  0xb67f48e2 in nsIOService::NewFileURI (this=0x80ee888, file=0x80eb410, result=0xbf9badc8) at nsIOService.cpp:500
#4  0xb68b3d67 in nsResProtocolHandler::AddSpecialDir (this=0x80eb0a0, aSpecialDir=0xb68e48ad "CurProcD", aSubstitution=@0xb7dfebf0)
    at nsResProtocolHandler.cpp:146
#5  0xb68b430a in nsResProtocolHandler::Init (this=0x80eb0a0) at nsResProtocolHandler.cpp:166
#6  0xb67d34dd in nsResProtocolHandlerConstructor (aOuter=0x0, aIID=@0xb68c4290, aResult=0xbf9baee4) at nsNetModule.cpp:213
#7  0xb7d232ea in nsGenericFactory::CreateInstance (this=0x80eb088, aOuter=0x0, aIID=@0xb68c4290, aResult=0xbf9baee4) at nsGenericFactory.cpp:79
#8  0xb7d8d3a1 in nsComponentManagerImpl::CreateInstanceByContractID (this=0x80a95f8, aContractID=0xbf9bafb4 "@mozilla.org/network/protocol;1?name=resource",
    aDelegate=0x0, aIID=@0xb68c4290, aResult=0xbf9baee4) at nsComponentManager.cpp:1981
#9  0xb7d8fefe in nsComponentManagerImpl::GetServiceByContractID (this=0x80a95f8, aContractID=0xbf9bafb4 "@mozilla.org/network/protocol;1?name=resource",
    aIID=@0xb68c4290, result=0xbf9bb0a0) at nsComponentManager.cpp:2408
#10 0xb7d1ec5c in CallGetService (aContractID=0xbf9bafb4 "@mozilla.org/network/protocol;1?name=resource", aIID=@0xb68c4290, aResult=0xbf9bb0a0)
    at nsComponentManagerUtils.cpp:94
#11 0xb67f36ee in CallGetService<nsIProtocolHandler> (aContractID=0xbf9bafb4 "@mozilla.org/network/protocol;1?name=resource", aDestination=0xbf9bb0a0)
    at ../dist/include/xpcom/nsServiceManagerUtils.h:130
#12 0xb67f4f10 in nsIOService::GetProtocolHandler (this=0x80ee888, scheme=0xbf9bb060 "resource", result=0xbf9bb0a0) at nsIOService.cpp:388
#13 0xb67f353c in nsIOService::NewURI (this=0x80ee888, aSpec=@0xbf9bb230, aCharset=0x0, aBaseURI=0x0, result=0xbf9bb22c) at nsIOService.cpp:479
#14 0xb692fc10 in NS_NewURI (result=0xbf9bb22c, spec=@0xbf9bb230, charset=0x0, baseURI=0x0, ioService=0x80ee888) at dist/include/necko/nsNetUtil.h:122
#15 0xb693db8a in nsChromeRegistry::CheckForNewChrome (this=0x80e3108) at nsChromeRegistry.cpp:1113
#16 0xb69397fa in nsChromeRegistry::Init (this=0x80e3108) at nsChromeRegistry.cpp:553
#17 0xb692be87 in nsChromeRegistryConstructor (aOuter=0x0, aIID=@0x806dc20, aResult=0xbf9bb474) at nsChromeFactory.cpp:50
#18 0xb7d232ea in nsGenericFactory::CreateInstance (this=0x80e30f0, aOuter=0x0, aIID=@0x806dc20, aResult=0xbf9bb474) at nsGenericFactory.cpp:79
#19 0xb7d8d3a1 in nsComponentManagerImpl::CreateInstanceByContractID (this=0x80a95f8, aContractID=0x806ca84 "@mozilla.org/chrome/chrome-registry;1",
    aDelegate=0x0, aIID=@0x806dc20, aResult=0xbf9bb474) at nsComponentManager.cpp:1981
#20 0xb7d8fefe in nsComponentManagerImpl::GetServiceByContractID (this=0x80a95f8, aContractID=0x806ca84 "@mozilla.org/chrome/chrome-registry;1", aIID=@0x806dc20,
    result=0xbf9bb540) at nsComponentManager.cpp:2408
#21 0xb7d1ec5c in CallGetService (aContractID=0x806ca84 "@mozilla.org/chrome/chrome-registry;1", aIID=@0x806dc20, aResult=0xbf9bb540)
    at nsComponentManagerUtils.cpp:94
#22 0xb7d1ed0a in nsGetServiceByContractID::operator() (this=0xbf9bb554, aIID=@0x806dc20, aInstancePtr=0xbf9bb540) at nsComponentManagerUtils.cpp:278
#23 0x08055524 in nsCOMPtr<nsIToolkitChromeRegistry>::assign_from_gs_contractid (this=0xbf9bb598, gs=
      {mContractID = 0x806ca84 "@mozilla.org/chrome/chrome-registry;1"}, aIID=@0x806dc20) at dist/include/xpcom/nsCOMPtr.h:1272
#24 0x08055588 in nsCOMPtr (this=0xbf9bb598, gs={mContractID = 0x806ca84 "@mozilla.org/chrome/chrome-registry;1"}) at dist/include/xpcom/nsCOMPtr.h:677
#25 0x08058fb2 in ScopedXPCOMStartup::SetWindowCreator (this=0xbf9bb740, native=0x8091348) at nsAppRunner.cpp:735
#26 0x0805d894 in XRE_main (argc=1, argv=0xbf9bb964, aAppData=0x8071020) at nsAppRunner.cpp:2258
#27 0x080504fc in main (argc=Cannot access memory at address 0xffffffff
) at nsMailApp.cpp:62
(gdb)
Here is another workaround, still only fixing the symptoms. Might this be related to http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31136 ?
I don't know if it is related, but I cannot get to work an homemade gcc 4.3 trunk firefox build under a virtualized Ubuntu Intrepid Ibex AMD64 which is using gcc 4.3.

I get a "*** buffer overflow detected ***: ./firefox-bin terminated" error message.

I will attach the error log I am getting.

gcc version used with Ubuntu Intrepid Ibex :

 gcc -v
Using built-in specs.
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.3.2-1ubuntu10' --with-bugurl=file:///usr/share/doc/gcc-4.3/README.Bugs --enable-languages=c,c++,fortran,objc,obj-c++ --prefix=/usr --enable-shared --with-system-zlib --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --enable-nls --with-gxx-include-dir=/usr/include/c++/4.3 --program-suffix=-4.3 --enable-clocale=gnu --enable-libstdcxx-debug --enable-objc-gc --enable-mpfr --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.3.2 (Ubuntu 4.3.2-1ubuntu10)
Flags: wanted1.9.1?
Flags: blocking1.9.1?
Can't block on this without more information or a cause identified. This is certainly not a generic problem because distros (and me personally) use GCC 4.3 all the time successfully.

Please reopen the bug if somebody can come up with a better diagnosis or identify particular config options that cause this.
Status: NEW → RESOLVED
Closed: 16 years ago
Flags: wanted1.9.1?
Flags: blocking1.9.1?
Flags: blocking1.9.1-
Resolution: --- → INCOMPLETE
Its been a long time since this bug showed up. 4.3 was still alpha/beta back in '06.  And firefox split into Xulrunner for the 3.0 release since then. 

I personally have not had this problem recurring as of late, so one would imagine the cause is long dead. 

I don't think I've seen this issue now for ~15 months, but I didn't even remember about this bug till the emails turned up lately. 

So its possibly still occurring on older ff, but its not happening to me now on 4.3s with FF3/3.1
Resolution: INCOMPLETE → FIXED
Resolution: FIXED → WORKSFORME
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: