Each OpenDevice() must eventually be matched by a call to CloseDevice(). All I/O requests must be complete before CloseDevice(). If any requests are still pending, abort them with AbortIO(). AbortIO(PrintIO); /* Ask device to abort request, if pending */ WaitIO(PrintIO); /* Wait for abort, then clean up */ CloseDevice((struct IORequest *)PrintIO); Use AbortIO() / WaitIO() Intelligently. ------------------------------------- Only call AbortIO()/WaitIO() for requests which have already been sent to the printer device. Using the AbortIO()/WaitIO() sequence on requests which have not been sent results in a hung condition.