Showing changes from revision #1 to #2:
Added | Removed | Changed
Entry | |
---|---|
R0 | Character to write |
Exit | |
---|---|
R0 | Preserved |
The purpose of this call is to send a character to all of the active output streams.
This SWI sends the byte in R0 to all active output streams (see OS_Byte 3 for specifying a stream). Do not assume that this SWI will never generate an error – it can and occasionally does.
Consider the case where output is redirected to a file on a filing system which has no space. This is the most common example.
A less common, but possible case is where an application displays a string in its Exit handler. Under a TaskWindow, if you close the window before the task has exited, its Exit handler is called. This should tidy up and exit. If it prints strings using non-X versions of the SWIs an error will be generated. This will call the Error handler, which will either display a message or call the Exit handler. In the former case, if X SWIs are used the Exit handler is usually called.
The outcome of this is that a TaskWindow can hog 99% of the processor time as it switches in and out of SVC mode incredibly quickly in an infinite sequence of errors. Avoid this by using X SWIs.