Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#208 closed bug (fixed)

Hyperlink hits

Reported by: Mikhail Malyshev Owned by:
Priority: normal Milestone: 4.0-2015R2
Component: Hyperlink.mcc Version: 4.0-nightly build
Severity: minor Keywords:
Cc: OS Platform: AmigaOS3
Blocked By: Blocking:
Release Notes:

Description

Summary

Hits when mouse hovers over example links

==============================================

18-Июн-15  20:05:08
WARNING: ENFORCER HIT!                                                        
LONG-WRITE to 00000000                  PC: 4BEFD7B8
USP:  449C8704 SR: 0010 FLSW: 00810200 TCB: 449B8FF0
Data: 44EC45AC 000009A8 00000068 00000058 00000000 449C8834 00000009 00000000
Addr: 00000000 44EF25C8 44EF25C8 449C875C 449C88D2 449C8780 44000BCC 449C8704
Stck: 44EC23F0 00000000 00000054 FFFFFFFF 449C88D2 00000073 44EC2444 00000054
Stck: 00000000 00000000 44EC1C48 00000054 00000000 FFFFFFFF 00000000 449C88D2
Stck: 44A55DFD 44EC1FD2 449C88D2 449C875C FFFFFFFF 4470F4EF 00000001 449C88B2
Stck: 00000014 00000000 00000000 00000000 00000000 00000000 00000104 4470F4E6
----> 4BEFD7B8 - "KickTag - exec 45.20 (6.1.2002)" Hunk 0001 Offset 000019FC
----> $4befd7b8: MOVE.L    A1,(A0)
----> $4befd7ba: RTS
----> $4befd7bc: ADDQ.B    #$1,$0127(A6)
----> $4befd7c0: MOVE.L    (A1)+,A0
----> 44EC23F0 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 00003F60
----> $44ec23f0: MOVE.L    $44ec45bc.L,D0
----> $44ec23f6: ADD.L     D2,D0
----> $44ec23f8: MOVE.L    D0,$44ec45bc.L
----> $44ec23fe: CMP.L     $44ec45b8.L,D0
----> 44EC2444 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 00003FB4
----> $44ec2444: ADDA.W    #$000c,A7
----> $44ec2448: RTS
----> $44ec244a: NOP
----> $44ec244c: MOVEQ     #$17,D0
----> 44EC1C48 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 000037B8
----> $44ec1c48: MOVE.L    D0,D2
----> $44ec1c4a: ADDQ.L    #$4,A7
----> $44ec1c4c: BNE.S     $44ec1c56
----> $44ec1c4e: MOVEQ     #$37,D0
----> 44EC1FD2 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 00003B42
----> $44ec1fd2: ADDQ.L    #$8,A7
----> $44ec1fd4: MOVEQ     #$ff,D1
----> $44ec1fd6: CMP.L     D0,D1
----> $44ec1fd8: BNE.S     $44ec1fee
----> 44EC148A - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 00002FFA
----> $44ec148a: ADDQ.L    #$4,A7
----> $44ec148c: TST.L     D0
----> $44ec148e: BGE.S     $44ec1494
----> $44ec1490: MOVE.L    D3,$0068(A7)
Name: "MUI"   
18-Июн-15  20:05:08
WARNING: ENFORCER HIT!                                                        
LONG-WRITE to 00000000                  PC: 4BEFD7D2
USP:  449C8920 SR: 0004 FLSW: 00810200 TCB: 449B8FF0
Data: 00000000 00000000 44EF25D8 00000005 44AC0000 FFFF0000 449C8A5C 449C8AF4
Addr: 44EC45AC 00000000 44EF25C8 44EED05C 00000000 449C895C 44000BCC 449C8920
Stck: 44EC1ACA 4470F4DC 44EED0E4 44000BCC 44EBFB20 44EF25D8 44ED9560 8042F8DC
Stck: 44EF25D8 00000000 44EECAB8 44EED0E4 44EBFB30 44EB3808 44EF25D8 44EDC7A8
Stck: 44EBFC88 44EB3884 44EECAB8 44EED0E4 44EECAB8 00000005 44EECAB8 44EBFB30
Stck: 00000000 44EDC7A8 44EB3808 449D7BF8 44EECAB8 449C8B10 440003E0 44A45AE6
----> 4BEFD7D2 - "KickTag - exec 45.20 (6.1.2002)" Hunk 0001 Offset 00001A16
----> $4befd7d2: MOVE.L    A0,(A1)
----> $4befd7d4: MOVE.L    A1,$0004(A0)
----> $4befd7d8: RTS
----> $4befd7da: MOVE.L    (A0),A1
----> 44EC1ACA - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 0000363A
----> $44ec1aca: MOVEQ     #$10,D2
----> $44ec1acc: ADD.L     $0008(A2),D2
----> $44ec1ad0: MOVE.L    $44ec45b4.L,D0
----> $44ec1ad6: BEQ.S     $44ec1aea
----> 44EBFB20 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 00001690
----> $44ebfb20: CLR.L     D0
----> $44ebfb22: ADDA.W    #$0014,A7
----> $44ebfb26: MOVEM.L   $ffec(A5),D2/A2-A3/A6
----> $44ebfb2c: UNLK      A5
----> 44EBFB30 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 000016A0
----> $44ebfb30: MOVEM.L   D2-D3/A2-A6,-(A7)
----> $44ebfb34: MOVE.L    A2,D1
----> $44ebfb36: MOVE.L    A1,A2
----> $44ebfb38: MOVE.L    (A2),D0
----> 44EBFC88 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 000017F8
----> $44ebfc88: ADDA.W    #$000c,A7
----> $44ebfc8c: BRA.S     $44ebfc9e
----> $44ebfc8e: MOVE.L    A2,-(A7)
----> $44ebfc90: MOVE.L    D1,-(A7)
----> 44EBFB30 - "LIBS:mui/Hyperlink.mcp" Hunk 0000 Offset 000016A0
----> $44ebfb30: MOVEM.L   D2-D3/A2-A6,-(A7)
----> $44ebfb34: MOVE.L    A2,D1
----> $44ebfb36: MOVE.L    A1,A2
----> $44ebfb38: MOVE.L    (A2),D0
----> 449D7BF8 - "LIBS:muimaster.library" Hunk 0000 Offset 00003E88
----> $449d7bf8: MOVEM.L   (A7)+,A2-A3/A6
----> $449d7bfc: RTS
----> $449d7bfe: ORI.B     #$49,D0
----> $449d7c02: CLR.W     (A3)
----> 44A45AE6 - "LIBS:muimaster.library" Hunk 0000 Offset 00071D76
----> $44a45ae6: MOVEM.L   (A7)+,A2/A6
----> $44a45aea: RTS
----> $44a45aec: MOVEM.L   D2-D4,-(A7)
----> $44a45af0: MOVE.L    $0018(A7),D1
Name: "MUI"   


Attachments (7)

hyperlink.png (122.0 KB) - added by Mikhail Malyshev 4 years ago.
Hyperlink_mcp.lha (79.9 KB) - added by Thore Böckelmann 4 years ago.
debug version of Hyperlink.mcp 20.4
hits (4.0 KB) - added by Mikhail Malyshev 4 years ago.
Hyperlink_mcp_20.5.lha (80.3 KB) - added by Thore Böckelmann 4 years ago.
debug version of Hyperlink.mcp 20.5 with debug output
hits.txt (17.5 KB) - added by Mikhail Malyshev 4 years ago.
inlined hits, debug, then 2 hits for each example
hits.log (17.5 KB) - added by Mikhail Malyshev 4 years ago.
combine serial log
Hyperlink_custom_vasprint.lha (16.6 KB) - added by Thore Böckelmann 4 years ago.
Hyperlink.mcp with custom vasprintf() implementation

Download all attachments as: .zip

Change History (37)

Changed 4 years ago by Mikhail Malyshev

Attachment: hyperlink.png added

comment:1 Changed 4 years ago by Mikhail Malyshev

And while you are looking into it, it would be nice to align the colour texts to the right (to the colour gadgets) as it is done in most other places for consistency of style.

comment:2 Changed 4 years ago by Thore Böckelmann

In 4740:

  • mcc/Hyperlink_mcp.c: changed the color label alignment. This refs #208.

comment:3 Changed 4 years ago by Thore Böckelmann

Component: Urltext.mccHyperlink.mcc

I cannot reproduce the hits here. For me everything is working perfectly. I will attach the debug version of Hyperlink.mcp, because the log of the normal version cannot be used to find the location of the hit in the debug binary.

Changed 4 years ago by Thore Böckelmann

Attachment: Hyperlink_mcp.lha added

debug version of Hyperlink.mcp 20.4

comment:4 Changed 4 years ago by Thore Böckelmann

Please try the debug version.

Changed 4 years ago by Mikhail Malyshev

Attachment: hits added

comment:5 Changed 4 years ago by Mikhail Malyshev

New hits attached.

No debug output on serial port, am I doing something wrong?!

Interestingly, hovering over urls in Prefs/Info has no problems

Also clicking urls has no effect, only MultiView works with startup text opened.

comment:6 Changed 4 years ago by Thore Böckelmann

There is nothing on the serial line, because the debug version does not output anything. It is just an unstripped binary with full debug information. However, the hits still do not point to any of my code within Hyperlink.mcp but to code of some clib2 functions like malloc(). There is not much I can do against this, because exactly the same binary works perfectly here on my WinUAE system.

Perhaps you didn't notice it, but the hits occur in Hyperlink.mcp, not Hyperlink.mcc.

If clicking the links has no effect then most probably you don't have OpenURL installed. Is that possible?

Last edited 4 years ago by Thore Böckelmann (previous) (diff)

comment:7 Changed 4 years ago by Mikhail Malyshev

OpenURL installed, also I had an older version on my test partition, an update to v 7.16 did not solve anything. Snoopy reports no activity on url clicks in MUI.

If the example links are the same as the ones in the MUI About and Info parts, why they don't cause hits when mouse hovers over them? They seem to behave the same and change colour according to settings, or the use the older plugin?.

comment:8 in reply to:  7 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

OpenURL installed, also I had an older version on my test partition, an update to v 7.16 did not solve anything. Snoopy reports no activity on url clicks in MUI.

Do you have a browser or mail client configured?

If the example links are the same as the ones in the MUI About and Info parts, why they don't cause hits when mouse hovers over them? They seem to behave the same and change colour according to settings, or the use the older plugin?.

Probably because they don't trigger any display of the hovered URI. This is implemented in Hyperlink.mcp's sample objects only.

comment:9 Changed 4 years ago by Mikhail Malyshev

I suspect the hits come from the point when some text is displayed in the example area (when mouse is over URI) not from the fact that URI is redrawn in different colour or the pointer changes. Might be a locale issue?!

OpenURL worked fine for me before and yes, it's configured.
Tried an AmigaSYS4 based install and there I have the same problem, nothing happens when you click URI.

Changed 4 years ago by Thore Böckelmann

Attachment: Hyperlink_mcp_20.5.lha added

debug version of Hyperlink.mcp 20.5 with debug output

comment:10 Changed 4 years ago by Thore Böckelmann

Try this new debug version of Hyperlink.mcp. It will output the parameters and the final example text when hovering the object.

comment:11 Changed 4 years ago by Mikhail Malyshev

on OS4 I get an error message that http client not defined (true, since it's the basic setup) on OS3 we don't get any messages, just sits quiet (apart from the hits) tested on different systems/setups with same results

on OS3 debug output….
it also does the same with translation, just replaces the Go to with translated word

URI 'http://www.example.com'
decoded URI 'http://www.example.com'
format sample text 'Go to %s' with 'http://www.example.com'
formatted sample text 'Go to http://www.example.com'
URI 'NULL'
formatted sample text 'NULL'
URI 'workbench:RAM%20Disk%3a'
decoded URI 'workbench:RAM Disk:'
format sample text 'Open %s' with 'RAM Disk:'
formatted sample text 'Open RAM Disk:'
URI 'NULL'
formatted sample text 'NULL'
URI 'amigados:SYS%3aUtilities/MultiView%20S%3aStartup-Sequence'
decoded URI 'amigados:SYS:Utilities/MultiView S:Startup-Sequence'
format sample text 'Launch %s' with 'SYS:Utilities/MultiView S:Startup-Sequence'
formatted sample text 'Launch SYS:Utilities/MultiView S:Startup-Sequence'
URI 'NULL'
formatted sample text 'NULL'
URI 'mailto:user@…'
decoded URI 'mailto:user@…'
format sample text 'Write mail to %s' with 'user@…'
formatted sample text 'Write mail to user@…'
URI 'NULL'
formatted sample text 'NULL'
URI 'amigados:SYS%3aUtilities/MultiView%20S%3aStartup-Sequence'
decoded URI 'amigados:SYS:Utilities/MultiView S:Startup-Sequence'
format sample text 'Launch %s' with 'SYS:Utilities/MultiView S:Startup-Sequence'
formatted sample text 'Launch SYS:Utilities/MultiView S:Startup-Sequence'
URI 'NULL'
formatted sample text 'NULL'
URI 'amigados:SYS%3aUtilities/MultiView%20S%3aStartup-Sequence'
decoded URI 'amigados:SYS:Utilities/MultiView S:Startup-Sequence'
format sample text 'Launch %s' with 'SYS:Utilities/MultiView S:Startup-Sequence'
formatted sample text 'Launch SYS:Utilities/MultiView S:Startup-Sequence'
URI 'NULL'
formatted sample text 'NULL'
x

comment:12 Changed 4 years ago by Thore Böckelmann

Is it possible to get an interleaved output of both Hyperlink.mcp and Enforcer? Otherwise it is impossible to guess when the hits happen compared to when which text is generated.

comment:13 Changed 4 years ago by Mikhail Malyshev

attached

what method is used to open wb ram: window ?

For me it only works in AOS4, nothing on OS3 WB or Opus5

Changed 4 years ago by Mikhail Malyshev

Attachment: hits.txt added

inlined hits, debug, then 2 hits for each example

comment:14 in reply to:  13 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

what method is used to open wb ram: window ?

OpenWorkbenchObject(). This function requires workbench.library V44+

For me it only works in AOS4, nothing on OS3 WB or Opus5

I know. I doesn't work for me either with DOpus Magellan as it is installed with AmiKit7. I think for AmiKit8 this hasn't changed. So if your workbench.library is too old or doesn't implement this function properly there is nothing that MUI could do against that.

comment:15 Changed 4 years ago by Mikhail Malyshev

Hmmm…. does not seem to work with v44, v45 or v50 lib
However, we can do it via arexx easily, and it will work for
all major desktops like WB, Opus5 or Scalos!

comment:16 in reply to:  15 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

Hmmm…. does not seem to work with v44, v45 or v50 lib
However, we can do it via arexx easily, and it will work for
all major desktops like WB, Opus5 or Scalos!

Why should ARexx work when the fundamental basics (workbench.library) don't work? I just switched my AmiKit system from DOpus to Workbench and the "RAM Disk:" link worked perfectly. It is DOpus' and Scalos' replacements/patches of workbench.library which don't work. I don't care if the original stuff works but custom replacements fail. I cannot tell for Scalos, but the current DOpus 5.9x only tries to launch programs via OpenWorkbenchObject(), but does not support opening the drawer windows. This is beyond MUI's scope to handle things.

Now back to the original topic. Your "hits.txt" file very much looks like you just manually inserted the debug output of Hyperlink.mcp between the Enforcer hits. The amount of empty lines is inconsistent and does in no way relay to the plain Enforcer logs. Sorry, but this is going to lead nowhere. Either you capture a real log which includes both the debug output and the Enforcer hits or we can stop here immediately.

comment:17 Changed 4 years ago by Mikhail Malyshev

Well, Arexx works for me here with all of them.

Direct WB call does not for some reason (for WB of course)
It must be related to something else apart from wb.lib itself.

Now how do I do a combined log if enforcer outputs data to one output and your.mcc to another.

The output from mcc and 2 hits happen at the same time when mouse hits the uri zone.

comment:18 in reply to:  17 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

Direct WB call does not for some reason (for WB of course)
It must be related to something else apart from wb.lib itself.

There isn't much one can do wrong here. OpenWorkbenchObject() takes a path and a taglist as parameters. The path is "RAM Disk:" for example and a taglist is not required. If that fails, then the implementation of the function is faulty, not MUI.

Now how do I do a combined log if enforcer outputs data to one output and your.mcc to another.

Both Enforcer and Hyperlink.mcp send their output to the serial line which can be captured with Sashimi. This is the most convenient way to get everything into one file while preserving the original order in which the individual lines were generated.

comment:19 Changed 4 years ago by Mikhail Malyshev

Ok, got the combined log from SER:

Solved the RAM Disk problem with WB.
On most of my systems it gets renamed on bootup, so there is no "RAM DISK:"
In theory RAM: should probably be available for everyone, since only the volume names get changed by some people.

And what do you think of expanding the window open function to Opus and Scalos ?
MUI can detect which desktop is active and call the equivalent rexx openwindow command for them. I can supply you with the commands required.

Changed 4 years ago by Mikhail Malyshev

Attachment: hits.log added

combine serial log

comment:20 in reply to:  19 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

Ok, got the combined log from SER:

And did you notice that there are substantial differences between this version and your own manually cranked up one? The hits happen when a new link is hovered, not when the active link is left. Your previous log pointed out the contrary, but this was wrong.

However, I still have no idea why setting up the new string causes hits, although both the format string and the decoded URI look good.

Solved the RAM Disk problem with WB.
On most of my systems it gets renamed on bootup, so there is no "RAM DISK:"
In theory RAM: should probably be available for everyone, since only the volume names get changed by some people.

I don't care if "RAM Disk:" cannot be accessed just because people rename "RAM Disk" to "RAM" to work around buggy programs that are not able to handle 100% valid paths containing spaces.

And what do you think of expanding the window open function to Opus and Scalos ?
MUI can detect which desktop is active and call the equivalent rexx openwindow command for them. I can supply you with the commands required.

No. Both Scalos and DOpus claim themselves to be a replacement for Workbench. The inner core of Workbench is the workbench.library. If both fail to implement certain functions as documented, then there is no point to work around these limitations by other means. If it is possible to open a drawer in a different why, then why isn't this possible in OpenWorkbenchObject() as well? Any other program calling OpenWorkbenchObject() will fail in exactly the same way. Do you expect each and every developer to specifically support 3 different desktop environments, just because two of them don't behave as documented?

Supporting special features of patches and other enhancements is one thing and can give you certain advantages. But don't expect me to jump through burning hoops, just because a patch is worse than the original.

comment:21 Changed 4 years ago by Thore Böckelmann

Since everything is working perfectly for me with both german locale as well as the built-in english strings. Even switching to russian locale does not make any difference.

Changed 4 years ago by Thore Böckelmann

Hyperlink.mcp with custom vasprintf() implementation

comment:22 Changed 4 years ago by Thore Böckelmann

Perhaps the vasprintf() replacement makes a difference. Please try it.

comment:23 Changed 4 years ago by Mikhail Malyshev

Good news, no hits now.

One thing remains however, the browser is not called on clicking URI.
Snoopy shows no activity.

Checked with older MUI, and the browser opens there without problems.
Snoopy shows some data passed.

comment:24 in reply to:  23 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

Good news, no hits now.

Great!

One thing remains however, the browser is not called on clicking URI.
Snoopy shows no activity.

Does C:OpenURL work for you? i.e "C:OpenURL http://www.muidev.de"

Checked with older MUI, and the browser opens there without problems.
Snoopy shows some data passed.

The old Urltext.mcc used exactly the same function with exactly the same parameters as Hyperlink.mcc does. And what kind of data does Snoopy show? You really should begin to provide information on your own if you mention them already. Or do I have to beg for every bit?

comment:25 Changed 4 years ago by Thore Böckelmann

In 4778:

  • mcc/Hyperlink_mcp.c: use a plain memory allocation plus snprintf() to set up the example text instead of asprintf(). This refs #208.

comment:26 Changed 4 years ago by Thore Böckelmann

In 4779:

  • mcc/Hyperlink.c: restore the original URI string in case following it via URL-Handler failed, otherwise openurl.library will get a URI string it cannot handle. This refs #208.

comment:27 Changed 4 years ago by Mikhail Malyshev

Finally, solved! All works as expected now.
The newer openurl on my mui4 test system required some extra options ticked in openurl prefs to get it working (launching the browser that is if some conditions were not met)

comment:28 Changed 4 years ago by Thore Böckelmann

Milestone: 4.0-2015R2
Priority: undecidednormal
Resolution: fixed
Status: newclosed

<sigh> Do you remember that I asked you 5 days ago already to check your OpenURL settings and you answered that everything was ok and working properly? If you switch back to an older MUI version and tell me that Urltext.mcc correctly opens HTTP links I must assume that your OpenURL settings remain unchanged. And now you tell me that just enabling an option in OpenURL magically made everything work as expected? Are you really expecting from me that I should take future tickets and answers from your side serious?

Anyway, I am glad this issue is finally solved now.

comment:29 Changed 4 years ago by Mikhail Malyshev

Sorry for the small confusion that caused. The v7 required some different advanced settings tweaked compared to original v4 openurl, or maybe just a resave of settings for upgrade. Sadly MUI had no error/warning messages to show and just kept silent. Glad that this one is over too. Where are the nightly updates ?

Last edited 4 years ago by Mikhail Malyshev (previous) (diff)

comment:30 in reply to:  29 Changed 4 years ago by Thore Böckelmann

Replying to Michael:

Sorry for the small confusion that caused. The v7 required some different advanced settings tweaked compared to original v4 openurl, or maybe just a resave of settings for upgrade.

V4 is ancient. V7 has been around since 2009.

Sadly MUI had no error/warning messages to show and just kept silent. Glad that this one is over too.

All it could tell you is that URL_Open() returned failure, but no details. So eventually you would have to check your OpenURL settings anyway.

Where are the nightly updates ?

Jens just triggered the build process manually. They are online again now.

Note: See TracTickets for help on using tickets.