MantisBT - NetSurf
View Issue Details
0002125NetSurfRISC OS-specificpublic2014-05-16 11:302014-05-29 17:08
ReporterGraham Thurlwell 
Assigned ToVincent Sanders 
PrioritynormalSeveritycrashReproducibilityalways
StatusclosedResolutionno change required 
PlatformA9homeOSRISC OSOS Version4.42
Product Version 
Target VersionFixed in Version 
Fixed in CI build #
Reported in CI build #1878
URL of problem pageN/A - happens as soon as NetSurf loaded.
Summary0002125: A9home locks up with Branch Through Zero after NetSurf loads.
DescriptionNetSurf will appear to load as normal but upon the very next key press or mouse button click - anywhere, doesn't have to be related to NetSurf itself - a Branch Through Zero error will occur. Any further interaction with the system, including trying to click on the error itself, will just repeat the error message.

The only way out of this position is to reset the machine by holding in the power button until the light goes red - Ctrl-Break doesn't work.
Steps To ReproduceIMPORTANT. This bug will only occur on an A9home with the Provide Compatibility HAL configure option enabled. With the option disabled NetSurf will work normally.

1. Check Provide Compatibility HAL option is enabled.
2. Load !NetSurf.
3. Once the app has loaded, press any key or mouse button. This includes clicking on the backdrop or hitting F12.
4. The Branch Through Zero error will trigger.
5. Any further clicks or key presses will repeat the error message.
Additional InformationThe Provide Compatibility HAL option is set in the Compatibility applet in RISC OS's Configure. The Compatibility applet is described at http://www.riscos.com/support/users/userguide6/config/compat.htm - the A9home's RISC OS 4.42 is an earlier version of what became RISC OS 6.

My current running config on my A9home is for all the options to be disabled with the exception of Accept Unheadered Files, which seems to be required by something in my boot sequence. In this setup NetSurf works fine, the crash only happens if I have Compatibility HAL enabled.
TagsNo tags attached.
Attached Fileszip btzerobug.zip (65,379) 2014-05-16 11:30
https://bugs.netsurf-browser.org/mantis/file_download.php?file_id=143&type=bug

Notes
(0000334)
Vincent Sanders   
2014-05-17 23:36   
This appears to be an Operating system issue which we cannot work around.

Thankyou for the report, it gives us a reference for anyone else with the problem.

However, that said, please do not be offended if I close this issue as we cannot fix it.

My only suggestion is to contact Advantage 6 and see if there is an update to the OS.
(0000337)
Graham Thurlwell   
2014-05-21 00:31   
Thanks for the feedback Vincent. Sadly your suggestion of contacting either Advantage 6 (manufacturer) or RISC OS Ltd (OS developer) for a newer version of the OS is not a solution for a variety of reasons - not least of which is development of that strand of the OS appears to have ceased.

If, indeed, the bug is not actually possible to solve may I suggest that a compromise solution would be to investigate whether there is a way to determine whether it's possible for !NetSurf to see if Compatibility HAL is enabled and put up an error if it is.

As I said in the report, if Compatibility HAL is /not/ enabled NetSurf works,
(0000338)
Graham Thurlwell   
2014-05-21 00:54   
(Last edited: 2014-05-21 00:55)
For the avoidance of doubt, this bug is exceptionally serious because the end result is that the entire machine is stiffed and the only way out is a hardware reset or a power cycle.

(0000339)
Rob Kendrick   
2014-05-21 08:46   
The issue is that we can't support the OS that's in the A9home. Only one of the developers has access to one, but doesn't have suitable debugging tools. The OS is known to be flaky and unfinished, and introduces controversial changes that break compatibility with a lot of things.

We can't do much here *OTHER* than recommend an OS upgrade or moving to some other hardware.
(0000340)
John-Mark Bell   
2014-05-21 22:17   
I presume you've attempted to load each of the many modules NetSurf depends on individually, to isolate the problem as being related to NetSurf itself, rather than in some other component it depends on?
(0000341)
Graham Thurlwell   
2014-05-22 00:06   
Thanks for the feedback. I've had no internet most of the week due to my router dieing on me and am still trying to catch up. I haven't tried the loading modules individually yet, I'll try to make some time tomorrow and report back.
(0000342)
David Pitt   
2014-05-22 11:56   
(Last edited: 2014-05-22 11:57)
I find I cannot reproduce the above error on my A9home, OS4.42, with NetSurf 3.2 1886.

However we have been here before, Oct 2008 on csa.hardware, see http://compgroups.net/comp.sys.acorn.hardware/a9-error/1405987

The LegacyHAL module in use is 0.02 (14 Jun 2009).

A quick revert shows there is a problem with LegacyHAL 0.01 (24 Apr 2006).

(0000343)
Graham Thurlwell   
2014-05-22 18:42   
OK, done some checking and Mr Bell's suggestion of loading the modules individually has yielded results. I worked down NetSurf's !Run file loading modules as I went and the offending module is CryptRandom - got the Branch Through Zero as soon as I clicked the mouse after I loaded it.

Version I have is 0.13, which is the version that ships with RISC OS NetSurf. For the record, the version of LegacyHAL on my A9home is v0.01 (24 Apr 2006), which is the problem version mentioned by Mr Pitt.

HTH!
(0000344)
Graham Thurlwell   
2014-05-22 19:34   
With the Compatibility HAL option turned off the LegacyHAL module isn't loaded, so could we have a check for the problem version in NetSurf's !Run file before the bit loading CryptRandom and halt with a warning if it's found?
(0000345)
Rob Kendrick   
2014-05-22 22:51   
If my reading of the usenet posting is correct, then upgrading the buggy OS module fixes the issue. ie, contact the vendor for an upgrade.

If we had to put a hack in !Run for every buggy OS module, I don't think some machines would have enough RAM to load it into memory before obeying it.

ie, do what was suggested in the first follow-up.
(0000346)
David Pitt   
2014-05-23 07:26   
LegacyHAL 0.02 can be found in A9Patch002.zip at http://www.theochem.ru.nl/~dtanis/riscos.html
(0000355)
Vincent Sanders   
2014-05-29 11:47   
Does The suggested OS update module fix this issue? Unless I hear from you soon I shall close this bug now the actual issue has been identified.
(0000358)
Graham Thurlwell   
2014-05-29 16:57   
Hi. The third-party update linked to above by David Pitt does solve the problem, I've been running NetSurf for a few days after the update was installed and haven't seen a Branch Through Zero since. Go ahead and close the bug, the info above should be enough if anyone else encounters it.

Issue History
2014-05-16 11:30Graham ThurlwellNew Issue
2014-05-16 11:30Graham ThurlwellFile Added: btzerobug.zip
2014-05-17 23:36Vincent SandersNote Added: 0000334
2014-05-17 23:36Vincent SandersStatusnew => closed
2014-05-17 23:36Vincent SandersResolutionopen => not fixable
2014-05-21 00:31Graham ThurlwellNote Added: 0000337
2014-05-21 00:31Graham ThurlwellStatusclosed => feedback
2014-05-21 00:31Graham ThurlwellResolutionnot fixable => reopened
2014-05-21 00:54Graham ThurlwellNote Added: 0000338
2014-05-21 00:54Graham ThurlwellStatusfeedback => new
2014-05-21 00:55Graham ThurlwellNote Edited: 0000338bug_revision_view_page.php?bugnote_id=338#r1222
2014-05-21 08:46Rob KendrickNote Added: 0000339
2014-05-21 08:47Rob KendrickResolutionreopened => won't fix
2014-05-21 22:17John-Mark BellNote Added: 0000340
2014-05-21 22:18John-Mark BellStatusnew => feedback
2014-05-22 00:06Graham ThurlwellNote Added: 0000341
2014-05-22 00:06Graham ThurlwellStatusfeedback => new
2014-05-22 11:56David PittNote Added: 0000342
2014-05-22 11:57David PittNote Edited: 0000342bug_revision_view_page.php?bugnote_id=342#r1224
2014-05-22 18:42Graham ThurlwellNote Added: 0000343
2014-05-22 19:34Graham ThurlwellNote Added: 0000344
2014-05-22 22:51Rob KendrickNote Added: 0000345
2014-05-23 07:26David PittNote Added: 0000346
2014-05-24 21:16Vincent SandersAssigned To => Vincent Sanders
2014-05-24 21:16Vincent SandersStatusnew => feedback
2014-05-29 11:47Vincent SandersNote Added: 0000355
2014-05-29 16:57Graham ThurlwellNote Added: 0000358
2014-05-29 16:57Graham ThurlwellStatusfeedback => assigned
2014-05-29 17:08Vincent SandersStatusassigned => closed
2014-05-29 17:08Vincent SandersResolutionwon't fix => no change required