Closed Bug 224427 Opened 21 years ago Closed 20 years ago

Get this when visiting the site: "Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'"

Categories

(Core Graveyard :: GFX: Gtk, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: mozilla, Assigned: blizzard)

References

()

Details

Attachments

(2 files)

User-Agent:       Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.6a) Gecko/20031029
Build Identifier: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.6a) Gecko/20031029

This warning appears when I visit the site www.ekstrabladet.dk or www.jp.dk:

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Reproducible: Always

Steps to Reproduce:
1.Go to one or the sites mentioned in 'Details'
2.The following line appears in the xterm where mozilla was started:
Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'


Actual Results:  
Mozilla seemed to continue, but at least one time I experienced that it froze,
however I don't know if that is related to this because mozilla sometimes do
crash and freeze.

Expected Results:  
Not show the warning and not crash or freeze.
i see thesame problem also in other sites. And also I have thesame problem with
srashing Mozilla. But i`m not sure if crashing Mozilla has something common with
this Gtk-WARNING (in other hand i don`t say that it hasn`t).

I`m working on Mozilla Nightlys, my last Mozilla was from 02 november and it
hadn`t this bug
Flags: blocking1.6b?
i have downloaded todays nightly and problem still egzist. could somebody work
on it? Mozilla still crashes and IMO it couldn`t be in 1.6b
I see this also on LInux 2003111005
I've seen this for a long time and suppose it has something to do with
the missing plugin dialog that pops up when Mozilla realizes, thet I don't
have Flash installed...
Status: UNCONFIRMED → NEW
Ever confirmed: true
i get 11 of these simply loading http://pub.tv2.no/nettavisen/ and i have flash
installed.

I get 7 of them loading http://aftenposten.no/
5 while loading http://vg.no/
etc. etc. etc.

Testing official build and current CVS, Linux
bryner, any idea what this is?
If the only symptom is a printf, I don't think this should block a release.  If
you're still seeing an intermittent crash/freeze, that should be filed as a
separate bug, referring to this one, with steps to reproduce the crash/freeze if
possible, but it doesn't sound like it's easy to reproduce.
Flags: blocking1.6b? → blocking1.6b-
Component: Embedding: GTK Widget → GFX: Gtk
The error is generated in plugin code, line 882 of ns4xPluginInstance.cpp
http://lxr.mozilla.org/mozilla/source/modules/plugin/base/src/ns4xPluginInstance.cpp#882

879   gpointer user_data = nsnull;
880   gdk_window_get_user_data(win, &user_data);
881   if (user_data) {
882     GtkWidget* widget = GTK_WIDGET(user_data);
883 
884     if (GTK_IS_SOCKET(widget))
885       isXembed = PR_TRUE;
886   }
Bug exists on Solaris as well:
Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.6a) Gecko/20031119
Still exists in Mozilla 1.6b/Solaris:
Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.6b) Gecko/20031210
Attached file Minimal test case
The sites referenced are dynamically generated and weren't always generating
the error message for me.  The attached file is a stripped down version which
consistently triggers the error message.  The original EMBED had a bunch of
other attributes and the type was "application/x-shockwave-flash", but none of
these details affected the behavior.  For some reason in Mozilla this file
gives only a warning, but in Firebird it gives a warning followed by a core
dump.
error still exists in Mozilla 1.6 (final release) - I am getting desperate...
IMHO this one should have been fixed before 1.6 final.. sad.
*** Bug 232511 has been marked as a duplicate of this bug. ***
Requires restart of mozilla 1.6. GIS has said it mat be related to Java VM. 
This problem is getting really bad. Yesterday I opened about 20 sites - out of
which 5 had Flash navigation - and I couldn't navigate at all... :-( So I had to
go to M$ Win2000... brrr! 

You should raise "severity" to "critical"!!!
Do we have any idea when this bug will be attended to?
It seems to slow the whole browser down.

I've noticed it with mozilla.org, ebay.co.uk, yahoo.com and yahoo.co.uk  so far.

None of these are to my knowledge using Flash so I don't think its just a
Plug-In problem.

Does this bug also occur with Firebird?

Lesley
Just tried out Firefox 0.8 with installed plug-in for Flashplayer. Crash w/o any
error message when accessing www.macromedia.com. I am definetely getting tired
of Mozilla products and probably switching to Opera soon...
if you're getting a crash, you're not seeing this bug.  read comment 7.
(In reply to comment #19)
> if you're getting a crash, you're not seeing this bug.  read comment 7.

I gave up with Mozilla - I installed Opera... that does not crash...
I believe the problem is caused by the GtkSuperWin widget in the Gtk1 version of
mozilla. Since the GtkSuperWin cannot be casted using GTK_WIDGET. So the
question is. How can the GtkSuperWin be correctly converted to a GTK_WIDGET so
an event handler can hook the "expose_event" callback. I believe the warning
Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'
is caused by the gtk_signal_connect callback.

I have seen this problem with my plugin I am writing mplayerplug-in. I don't see
this problem when the plugin is in GTK2 mode. 

Kevin
This is showing up on FreeBSD/Gnome/Mozilla 1.6 also.  Script
related, we think.  Frustrating, ($top | grep moz ... /bin/kill mozilla.pid")
Fortunately X and Gnome are staying up ... gotta love 'Nix....

"About" says:  Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.6) Gecko/20040212

More info, ref:  http://www.freebsdforums.org/forums/showthread.php?postid=107711

Similar circumstances occur whether we run mozilla, mozilla-gtk1, mozilla-gtk2 ...
GtkSuperWin was never a full fledged widget - that was the whole point.  If
you're writing a plugin that wants to work in a gtk 1.2 environment you need to
use Xt.  If you're using a recent moz with gtk2, you can use gtk2 plugins if you
use the guide that I posted a couple of weeks ago on Mozilla.org
I don't know if this related or not - but there is another bug reported:

http://bugzilla.mozilla.org/show_bug.cgi?id=200829

I noticed that my XF86 was set to color depth 15 - although the config file said
16. I set it now to 32 and all flash peoblems - with Mozilla, Firefox and Opera
disappeared!!!
*** Bug 237781 has been marked as a duplicate of this bug. ***
This problem may still exist in 1.7a and I have not encountered it in 1.4 and
1.5,so I use 1.5 instead.
I tried 1.7b today,  this problem still exists .
(In reply to comment #27)
> I tried 1.7b today,  this problem still exists .

Exist for me on moz 1.4,1.6,1.7b. question: r all these crashes only in remote x
envirnments?
*** Bug 241325 has been marked as a duplicate of this bug. ***
I tried 1.7rc2 in RedHat9 today, this problem may still exist.
*** Bug 244983 has been marked as a duplicate of this bug. ***
I tried 1.7rc3 just now in RedHat9,I met such messages again.But why?
The same error for me. Testsite: games.yahoo.com
This 

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

seemed to go through all mozilla versions, including the one I'm using now:

Mozilla 1.7
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7) Gecko/20040608

The problem is that one gets less space to work on a console; one has to open a
"throw-away"- console only for mozilla, since other errors can undergo in the
eruption of invalid casts from the zilla vulcane. It nerves.
Maybe the same in 1.7.
*** Bug 247783 has been marked as a duplicate of this bug. ***
(In reply to comment #34)
> Maybe the same in 1.7.

I get this in 1.7

nikoli@linux:~/Programs/mozilla> ./mozilla
LoadPlugin: failed to initialize shared library /home/nikoli/Programs/mozilla/pl
ugins/java2/plugin/i386/ns600/libjavaplugin_oji.so [/home/nikoli/Programs/mozill
a/plugins/java2/plugin/i386/ns600/libjavaplugin_oji.so: undefined symbol: __vt_1
7nsGetServiceByCID]

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'
====================================================================

Mozilla is crashing all the time on me... and if it's not crashing... it's very
slow and seemingly unresponsive.
Attachment #153713 - Flags: superreview?(blizzard)
Attachment #153713 - Flags: review?(bryner)
Attachment #153713 - Flags: superreview?(blizzard) → superreview+
Attachment #153713 - Flags: review?(bryner) → review?(caillon)
Confirmed with Firefox 0.9.
Thanks :)
Attachment #153713 - Flags: review?(caillon) → review+
Patch checked in (which should at least prevent the warning from being displayed):

Checking in ns4xPluginInstance.cpp;
/cvsroot/mozilla/modules/plugin/base/src/ns4xPluginInstance.cpp,v  <-- 
ns4xPluginInstance.cpp
new revision: 1.123; previous revision: 1.122
done
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Those messages came again when mozilla1.7.2 was used,but nothing came when
firefox0.9.3 was used.
The messages should continue to appear in both Firefox 0.9.3 and Mozilla 1.7.2,
since the patch was only checked in on the trunk.
*** Bug 276958 has been marked as a duplicate of this bug. ***
Please clarify whether the patch eliminates the invalid cast, or simply
surpresses the warning.  Which versions have the patch?

I have found another bug that may or may not be the same.  If I go to 
http://ww2.aaa.com/scripts/WebObjects.dll/AAAOnline.woa/208?association=aaa&club=240&page=CarFaxHome&sessionRedirect=1108609820093,
log in, and click on the link "Get started with a Free CARFAX Lemon Check", the
page fails to display (I get the message "Loading Page" instead.  In 1.7.5, I
get the gtk error message described above.  In 1.8b, the page still fails to
display, but I don't get an error message.
*** Bug 284479 has been marked as a duplicate of this bug. ***
(In reply to comment #44)
> *** Bug 284479 has been marked as a duplicate of this bug. ***

I agree Bug 284479 is dulicate of this bug.  Nevertheless the status of this bug
is described as RESOLVED FIXED yet it is still happening in Mozilla 1.7.3
Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.7.3) Gecko/20040919.

What is it I don't understand?

Thanks,
1.7.3 is old.
Comment 41 says the patch was checked into the trunk, so it's fixed in 1.8
development line.
Try to reproduce it with 1.8 beta, it should be fixed there.
But what about later 1.7.x versions??? Is it fixed in 1.7.5 and/or the upcoming
1.7.6?
I don't think so, as far as I see it it's just an annoying message, not a
critival bug.
*** Bug 284479 has been marked as a duplicate of this bug. ***
*** Bug 294904 has been marked as a duplicate of this bug. ***
I see this Gtk-WARNING in Mozilla 1.7.8 on http://www.nbc5i.com and on
http://www.ekstrabladet.dk .  Twice, Mozilla and X have crashed when viewing
http://www.ncb5i.com/weather/index.html but most times just see the
Gtk-WARNINGs.  Firefox 1.04 does not generate any Gtk-WARNING messages on those
sites.  Perhaps I need a newer distro?  Am using Slackware 9.1, Linux kernel 2.6.6.
Hello there,
is the patch to be applied on the source file from mozilla??
couldn't find ns4xPluginInstance.cpp on my system

I have the same problem using Netscape 7.2 on fedora core 4
Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

I used to use netscape for years and never had this problem,since i recently
installed Fedora core 4 (previous OS: Red hat fedora core 1 )
Hi,
It is not fixed.
I still get it in Mozilla 1.7.12.
These are the errors.
Can someone please check the patch into the 1.7 branch?
Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'

Gtk-WARNING **: invalid cast from `GtkSuperWin' to `GtkWidget'
                                                               
                                                               
Attachment #153713 - Flags: approval1.7.13?
Attachment #153713 - Flags: approval-aviary1.0.8?
Flags: blocking1.7.13?
Comment on attachment 153713 [details] [diff] [review]
this patch eliminates the warning

Not a critical blocker for  old branches, approval denied per drivers
Attachment #153713 - Flags: approval1.7.13?
Attachment #153713 - Flags: approval1.7.13-
Attachment #153713 - Flags: approval-aviary1.0.8?
Attachment #153713 - Flags: approval-aviary1.0.8-
Flags: blocking1.7.13? → blocking1.7.13-
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: