Page 1 of 2

Exec Bug Report

PostPosted: Sun Sep 09, 2018 2:10 am
by rwo
Okay .. I'm on a roll .. this very old Exec function crashes.. IExec->Alert();

exec.library 53.94 (03/03-2017) (A1222 version)

Code: Select all

#include <proto/exec.h>

int main( int argc UNUSED, char **argv UNUSED )
{
   IExec->Alert( 0 );

   return( 0 );
}


Re: Exec Bug Report

PostPosted: Tue Nov 20, 2018 2:33 pm
by broadblues
When you say it "crashes" what do you see?

What you *should* see is Grim Reaper displaying the Alert number you passed to IExec->Alert(). Ie 00000000 in the test case you wrote above.

Alerts() have been redirected to GRs for sometime now.

Re: Exec Bug Report

PostPosted: Wed Apr 24, 2019 7:58 am
by Hypex
broadblues wrote:What you *should* see is Grim Reaper displaying the Alert number you passed to IExec->Alert(). Ie 00000000 in the test case you wrote above.


Generally this is true but to my understanding only the deadend type should evoke a Grim Reaper. A zero alert value should fall under the recover type and evoke a yellow alert. Last time I checked this was still the case. I'm not aware of any change in this behaviour. Though it would in fact be a welcome change as a yellow alert kills multitasking which in turn kills USB input devices.

Code: Select all
#define AT_DeadEnd   0x80000000
#define AT_Recovery   0x00000000

Re: Exec Bug Report

PostPosted: Wed Apr 24, 2019 8:40 pm
by broadblues
No all crash alerts are redirected to the GR (from FE at least, possibly earlier) haven't seen a 'yellow alert' for quite a while.

Re: Exec Bug Report

PostPosted: Sun Apr 28, 2019 5:29 pm
by Hypex
I just tested an old Alert program I wrote and bug fixed last year. Running it now it keeps bringing up a GR which isn't right. The SDK says nothing about it but the function has certainly changed. This is on my X1000.

Re: Exec Bug Report

PostPosted: Mon Apr 29, 2019 12:05 pm
by broadblues
Running it now it keeps bringing up a GR which isn't right


This is how alerts are dealt with now, classic style yelow recevreable alrts kill the system, so are no longer appropriate, so yes it *is* "right".

There is no real reason to use an alert on Amiga OS4 anyway.

Re: Exec Bug Report

PostPosted: Mon Apr 29, 2019 12:42 pm
by Hypex
broadblues wrote:This is how alerts are dealt with now, classic style yelow recevreable alrts kill the system, so are no longer appropriate, so yes it *is* "right".

There is no real reason to use an alert on Amiga OS4 anyway.


It's not right for my program which uses the alert function to bring up an alert. ;-) The Grim Reaper makes it look like it's crashed. When it hasn't and the message from the program isn't displayed at all. It looks confusing now. I wrote it on my A1200 years ago so it's a 68K program. IIRC there were two functions in the system for user alerts.

In any case the yellow alerts never looked right on OS4. They overwrote the screen instead of pushing it down. Since screen dragging was supported I saw no reason for them not to push down the screen.

Re: Exec Bug Report

PostPosted: Mon Apr 29, 2019 5:02 pm
by trixie
Hypex wrote:It's not right for my program which uses the alert function to bring up an alert. ;-)

Why not use a requester for that instead?

Re: Exec Bug Report

PostPosted: Mon Apr 29, 2019 5:39 pm
by thomasrapp
trixie wrote:
Hypex wrote:It's not right for my program which uses the alert function to bring up an alert. ;-)

Why not use a requester for that instead?


Interesting suggestion because the documentation says that if the requester fails to open, it will revert to an alert. Now we have an infinite loop, don't we.

I wouldn't say something about IExec-Alert, because it is meant to show an error code. Displaying this in a GrimReaper is ok.

But the GR also opens for IIntuition->DisplayAlert and IIntuition->TimedDisplayAlert. I surely consider this a bug. These functions are meant to give some information to the user if everything else fails. But if a GR opens instead, the information is lost.

Besides that these functions are meant as a last resort if the system is almost dead. In such situation the GR cannot run any more, too.

Re: Exec Bug Report

PostPosted: Tue Apr 30, 2019 1:36 pm
by Hypex
trixie wrote:Why not use a requester for that instead?


Because my original program was intended to use alerts and the shock value they provide. I originally wrote it as a prank that acted as if a virus had entered the system. It used to do a tease and provide some options for left mouse and right mouse and indicate it was trying to kill a virus. But either way it just looked worse! Finally after three "levels" it stopped playing games and the virus was gone. :lol:

It could be translated to use requesters but the effect wouldn't be the same. And you'd need to press a gadget. Just not the same look and feel as a shocking warning on screen with the immediate action of left or right mouse. :)

I could emulate the effect but that is beyond the scope of the program.