Hello,
I know this thread is a little bit dislocatedt but,
I discovered some weird (so I think problem
running my Turbo Pascal OS... The main Kernel is
compiled with Turbo Pascal 7.0 and therefor follows
some of the .EXE behaviours of DOS programs. My problem:
I would like to trap all errors that normaly would
cause the program to terminate. To achieve this I wrote
my own Exitprocedure. This Procedure uses a Assembler Call
to jump to my Consoleprocedure.
If a error is cast, the kernel jumps to the exit procedure,
prints the error to the screen an returns to the console
that is a normal I/O repeat until loop inside a procedure.
After own error this works fine, the kernel keeps working as
normal but if a second error is cast, the kernel hangs or
I don't know exactly reboots (A reboot is my normal Kernel exit method)
Any Idea to keep it alive after a second/third error?
Exitprocedures?
Re:Exitprocedures?
Perhaps I'm being dense, but I don't understand this part. It sounds like you are saying that if a process causes an exception (such as divide-by-zero ), you switch to a console process that reports the nature of the exception. What are you trying to keep alive? What is generating the second exception?? A separate process?? You may simply be double-faulting. I can't tell from the description.drasir wrote: Hello,
returns to the console
that is a normal I/O repeat until loop inside a procedure.
Re:Exitprocedures?
Well, what I was trying to explain was:
The Kernelprogram runs a console to process user
input after initializing all needed functions.
The Console is a Procedure, after a command is
entered the procedure passes this command to a second procedure responcible for processing.
I don't switch to the console on error, it runs all the time.
I tryied to call the procedure several times in a row and
it worked fine.
Now when a error happens (I provoke them with runerror(xxx); it should behave like this...
Console -> "Do error"
-> Exitprocedure -> Display Error
-> Jump to console (repeat normal progress)
This Part works fine, but if i know provoke the second
error (from the new loaded console) the system crashes.
The Kernelprogram runs a console to process user
input after initializing all needed functions.
The Console is a Procedure, after a command is
entered the procedure passes this command to a second procedure responcible for processing.
I don't switch to the console on error, it runs all the time.
I tryied to call the procedure several times in a row and
it worked fine.
Now when a error happens (I provoke them with runerror(xxx); it should behave like this...
Console -> "Do error"
-> Exitprocedure -> Display Error
-> Jump to console (repeat normal progress)
This Part works fine, but if i know provoke the second
error (from the new loaded console) the system crashes.