Has anyone successfully used the limited signals capability of Unicon under beloved Windows? I attempted a very basic application of these features but had no success.
Program 1:
procedure main()
# get process number so I know its ID when I run other program
p := getpid()
# set up procedure to be executed when signal received
trap("SIGSEGV",trapp)
# make program do something until I run other program
repeat {
if kbhit() then break
write(p)
delay(1000)
}
end
# make program write message when signal received
procedure trapp(s)
write("Signal trapped ",s)
end
Assuming that Program 1 when running has a process ID of 233, running the next program doesn't do anything.
procedure main()
kill(233,"SIGSEGV")
end
I expected that executing Program 2 would send a signal to Program 1 causing the "trapp" procedure to be executed. What am I missing here?
Regards,
Daniel J. Boulet
