T3D 1.1 Beta 3 - Web plugin for FireFox fails to compile and load on 64b Windows 7 - RESOLVED
by GameArt Studio GmbH · in Torque 3D Professional · 11/01/2010 (1:53 pm) · 7 replies
Build: 1.1 Beta 2 and 3
Platform: Windows 7 64 bit
Target: (tested platform) Mozilla Firefox and Windows 7 64 bit
Issues:
Out of the box the web plugin will crash.
Edit: In fact you need to compile all once, then it screws up.
Steps to Repeat:
1. Just launch the web plugin for any demo project, it will crash and take the browser with it.
Suggested Fix:
Find this sourcefile for the NP Plugin: npPlugin.cpp
In the function: MY_NPVARIANT_TO_STRING
delete or comment out this line:
result[NPVARIANT_TO_STRING(f).UTF8Length] = '�¯�¿�½';
Should be line 45.
The line seems to be both wrong and useless.
cheers,
Thomas Lobig from GameArt Studio GmbH
Platform: Windows 7 64 bit
Target: (tested platform) Mozilla Firefox and Windows 7 64 bit
Issues:
Out of the box the web plugin will crash.
Edit: In fact you need to compile all once, then it screws up.
Steps to Repeat:
1. Just launch the web plugin for any demo project, it will crash and take the browser with it.
Suggested Fix:
Find this sourcefile for the NP Plugin: npPlugin.cpp
In the function: MY_NPVARIANT_TO_STRING
delete or comment out this line:
result[NPVARIANT_TO_STRING(f).UTF8Length] = '�¯�¿�½';
Should be line 45.
The line seems to be both wrong and useless.
cheers,
Thomas Lobig from GameArt Studio GmbH
#2
11/01/2010 (9:39 pm)
Web plugin works fine for me (although apparently if you stick a hyphen in the project name, not so much...). I'm running Windows 7 x64 Ultimate and Firefox 3.6.12.
#3
11/01/2010 (9:43 pm)
Just to go ahead and get the usual troubleshooting tasks out of the way, make sure your DirectX and video drivers are up to date.
#4
Refer to this post:
http://www.torquepowered.com/community/forums/viewthread/115041/1#comment-755329
11/02/2010 (8:16 am)
If you compile the plugin, the mentioned line get's compiled in and effectively breaks the build (for non-IE browsers)Refer to this post:
http://www.torquepowered.com/community/forums/viewthread/115041/1#comment-755329
#5
11/11/2010 (3:23 pm)
Logged as TQA-1197 for the QA team to verify.
#6
I've put in a fix for 1.1 Final. GameArt Studio is correct in that attempting to terminate a std::string is the wrong thing to do. Deleting that line is the correct first step.
However, we need to go a step further. My reading indicates that a NPString is not guaranteed to be NULL terminated. So the conversion line as it stands now:
can result in reading past the correct characters. Crash, meet burn. I replaced this line with the following:
How more people didn't get hit with this (including me!) likely just comes down to dumb luck.
- Dave
02/07/2011 (8:29 am)
Greetings!I've put in a fix for 1.1 Final. GameArt Studio is correct in that attempting to terminate a std::string is the wrong thing to do. Deleting that line is the correct first step.
However, we need to go a step further. My reading indicates that a NPString is not guaranteed to be NULL terminated. So the conversion line as it stands now:
result = NPVARIANT_TO_STRING(f).UTF8Characters;
can result in reading past the correct characters. Crash, meet burn. I replaced this line with the following:
NPString str = NPVARIANT_TO_STRING(f); result = std::string(str.UTF8Characters, str.UTF8Length);
How more people didn't get hit with this (including me!) likely just comes down to dumb luck.
- Dave
#7
04/18/2011 (3:36 pm)
Fixed in 1.1 Final and Preview.
Associate Scott Burns
GG Alumni