From: Jeremy W. <jez...@ho...> - 2008-04-06 11:21:52
|
All, I am getting a crash when using Perl 5.10 and Win32::GUI 1.6. The same application doesn't crash under 5.8.7 or 5.8.8. I've tracked down the "problem", but I'm not convinced it's the actual underlying issue. The crash was occurring at: GUI_Helpers.cpp line 757 proc WindowsHookMsgProc When I was selecting from the main menu of the application. The problem is the line: arrayref = av_fetch(perlud->avHooks, WM_TRACKPOPUP_MSGHOOK, 0); where: perlud->avHooks contains zero (NULL) Simply adding: if (perlud->avHooks !=NULL ) { before the call to the av_fetch stops the crash and the application runs normally. A potentially related issue is that I'm also getting: Can't call method "STORE" on an undefined value during global destruction. When the application exits. Again, this doesn't happen under 5.8.7 or 5.8.8. I am therefore suspecting a reference count issue somewhere? Any thoughts? I am going to try and create a simple test case. Cheers, jeremy. _________________________________________________________________ Amazing prizes every hour with Live Search Big Snap http://www.bigsnapsearch.com |
From: Jeremy W. <jez...@ho...> - 2008-04-06 17:54:27
|
Ok: Found a simple way to reproduce the error: Can't call method "STORE" on an undefined value during global destruction. It doesn't seem related to the crash. The stripped down example below is odd as most of the code doesn't make sense (!) but if you comment out any of the lines it doesn't show the error. The error happens with the stock Win32::GUI 1.6 ppm and with the mingw built source under Perl 5.10 (activestate build 1002). I suspect the hook method - but I'm lost...Thoughts? Cheers, jeremy. ######################## use Win32::GUI(); use strict; my @rows; for (0..250) { push @rows,'abc'; } my $win = new Win32::GUI::Window (-name => "win"); $win->Hook(32768+3,sub {}); my $label = $win->AddLabel(-name => "abc"); #print "$win $label\n"; sub Message3 {$win->Hide();}; _________________________________________________________________ Get Hotmail on your mobile. Text MSN to 63463 now! http://mobile.uk.msn.com/pc/mail.aspx |
From: Jeremy W. <jez...@ho...> - 2008-04-13 09:03:26
|
Hi, I've spent some more time on this. I've created a bug report on sourceforge so this isn't lost: http://sourceforge.net/tracker/index.php?func=detail&aid=1941241&group_id=16572&atid=116572 Ok - it's not a hook issue, it looks like its just the normal destruction process which seems different under 5.10. Any changes to the code below (such as commenting out a line) changes the destruction order and thus the message isn't reproduced. Spent a while looking through the code, (Win32::GUI::WindowProps) and I admit I'm stumped:) Is all this functionality to support accessing the internals of an object? I thought that was deprecated functionality? As a side, I couldn't get Win32::GUI to crash because of this issue but it does mean that the script doesn't finish correctly - which in turn could have other issues (such as with PerlApp). Cheers, jez. > From: jez...@ho... > To: per...@li... > Date: Sun, 6 Apr 2008 17:54:27 +0000 > Subject: Re: [perl-win32-gui-hackers] Crash with perl 5.10 and Win32::GUI 1.6 > > > Ok: > > Found a simple way to reproduce the error: > > Can't call method "STORE" on an undefined value during global destruction. > > It doesn't seem related to the crash. The stripped down example below is odd as most of the code doesn't make sense (!) but if you comment out any of the lines it doesn't show the error. The error happens with the stock Win32::GUI 1.6 ppm and with the mingw built source under Perl 5.10 (activestate build 1002). I suspect the hook method - but I'm lost...Thoughts? > > Cheers, > > jeremy. > > ######################## > use Win32::GUI(); > use strict; > > my @rows; > for (0..250) { push @rows,'abc'; } > > my $win = new Win32::GUI::Window (-name => "win"); > $win->Hook(32768+3,sub {}); > my $label = $win->AddLabel(-name => "abc"); > > #print "$win $label\n"; > sub Message3 {$win->Hide();}; > > _________________________________________________________________ > Get Hotmail on your mobile. Text MSN to 63463 now! > http://mobile.uk.msn.com/pc/mail.aspx > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Register now and save $200. Hurry, offer ends at 11:59 p.m., > Monday, April 7! Use priority code J8TLD2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Perl-Win32-GUI-Hackers mailing list > Per...@li... > https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-hackers > http://perl-win32-gui.sourceforge.net/ _________________________________________________________________ The next generation of Windows Live is here http://www.windowslive.co.uk/get-live |
From: Jeremy W. <jez...@ho...> - 2008-04-13 09:51:15
|
Hi, I've created the following tracker item for this issue: http://sourceforge.net/tracker/index.php?func=detail&aid=1941264&group_id=16572&atid=116572 I think the solution is straightforward but don't want to commit the code yet. As a side, I use the Win32::GUI::Coolbar module from Robs homepage: http://www.robmay.me.uk/win32gui and it needs updating to run under 1.6 (constants). I don't mind updating this module and would support it's move into the core. Cheers, jez. > From: jez...@ho... > To: per...@li... > Date: Sun, 6 Apr 2008 11:21:53 +0000 > Subject: [perl-win32-gui-hackers] Crash with perl 5.10 and Win32::GUI 1.6 > > > All, > > I am getting a crash when using Perl 5.10 and Win32::GUI 1.6. The same application doesn't crash under 5.8.7 or 5.8.8. I've tracked down the "problem", but I'm not convinced it's the actual underlying issue. The crash was occurring at: > > GUI_Helpers.cpp line 757 proc WindowsHookMsgProc > > When I was selecting from the main menu of the application. The problem is the line: > > arrayref = av_fetch(perlud->avHooks, WM_TRACKPOPUP_MSGHOOK, 0); > > where: > > perlud->avHooks > > contains zero (NULL) > > Simply adding: > > if (perlud->avHooks !=NULL ) { > > before the call to the av_fetch stops the crash and the application runs normally. > > A potentially related issue is that I'm also getting: > > Can't call method "STORE" on an undefined value during global destruction. > > When the application exits. Again, this doesn't happen under 5.8.7 or 5.8.8. I am therefore suspecting a reference count issue somewhere? Any thoughts? I am going to try and create a simple test case. > > Cheers, > > jeremy. > > > > > _________________________________________________________________ > Amazing prizes every hour with Live Search Big Snap > http://www.bigsnapsearch.com > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Register now and save $200. Hurry, offer ends at 11:59 p.m., > Monday, April 7! Use priority code J8TLD2. > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Perl-Win32-GUI-Hackers mailing list > Per...@li... > https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-hackers > http://perl-win32-gui.sourceforge.net/ _________________________________________________________________ The next generation of Windows Live is here http://www.windowslive.co.uk/get-live |
From: Robert M. <rob...@us...> - 2008-05-01 22:14:48
|
Jez, Thanks for the report and taking the time to look into this. I've not had a chance to look at what you've done yet, but should get some time in the next couple of weeks. Thanks, Rob. 2008/4/13 Jeremy White <jez...@ho...>: > > Hi, > > I've created the following tracker item for this issue: > > http://sourceforge.net/tracker/index.php?func=detail&aid=1941264&group_id=16572&atid=116572 > > I think the solution is straightforward but don't want to commit the code yet. > > As a side, I use the Win32::GUI::Coolbar module from Robs homepage: > > http://www.robmay.me.uk/win32gui > > and it needs updating to run under 1.6 (constants). I don't mind updating this module and would support it's move into the core. > > > Cheers, > > jez. > > > From: jez...@ho... > > To: per...@li... > > Date: Sun, 6 Apr 2008 11:21:53 +0000 > > Subject: [perl-win32-gui-hackers] Crash with perl 5.10 and Win32::GUI 1.6 > > > > > > > > All, > > > > I am getting a crash when using Perl 5.10 and Win32::GUI 1.6. The same application doesn't crash under 5.8.7 or 5.8.8. I've tracked down the "problem", but I'm not convinced it's the actual underlying issue. The crash was occurring at: > > > > GUI_Helpers.cpp line 757 proc WindowsHookMsgProc > > > > When I was selecting from the main menu of the application. The problem is the line: > > > > arrayref = av_fetch(perlud->avHooks, WM_TRACKPOPUP_MSGHOOK, 0); > > > > where: > > > > perlud->avHooks > > > > contains zero (NULL) > > > > Simply adding: > > > > if (perlud->avHooks !=NULL ) { > > > > before the call to the av_fetch stops the crash and the application runs normally. > > > > A potentially related issue is that I'm also getting: > > > > Can't call method "STORE" on an undefined value during global destruction. > > > > When the application exits. Again, this doesn't happen under 5.8.7 or 5.8.8. I am therefore suspecting a reference count issue somewhere? Any thoughts? I am going to try and create a simple test case. > > > > Cheers, > > > > jeremy. > > > > > > > > > > _________________________________________________________________ > > Amazing prizes every hour with Live Search Big Snap > > http://www.bigsnapsearch.com > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > > Register now and save $200. Hurry, offer ends at 11:59 p.m., > > Monday, April 7! Use priority code J8TLD2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > > _______________________________________________ > > Perl-Win32-GUI-Hackers mailing list > > Per...@li... > > https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-hackers > > http://perl-win32-gui.sourceforge.net/ > > _________________________________________________________________ > The next generation of Windows Live is here > http://www.windowslive.co.uk/get-live > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Don't miss this year's exciting event. There's still time to save $100. > Use priority code J8TL2D2. > > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Perl-Win32-GUI-Hackers mailing list > Per...@li... > https://lists.sourceforge.net/lists/listinfo/perl-win32-gui-hackers > http://perl-win32-gui.sourceforge.net/ > |