Carbon


DeferUserFn

Header: MacMemory.h Carbon status: Unsupported

Determines whether code that might cause page faults can safely be called immediately.

OSErr DeferUserFn (
    UserFnUPP userFunction, 
    void *argument
);
Parameter descriptions
userFunction

The address of the function to run.

argument

A pointer to the argument to pass to the specified function.

function result

A result code. A result code.

DISCUSSION

If the code can be called safely, DeferUserFn calls the function you designate in the parameter userFunction, with register A0 containing the value you designate in the parameter argument. If a page fault is in progress, however, the function address and its parameter are saved, and the function is deferred until page faults are again permitted.

Note that the function might be called immediately (before returning to the caller of DeferUserFn). Deferred functions must follow the register conventions used by interrupt handlers: they can use registers A0–A3 and D0–D3, and they must restore all other registers used.

AVAILABILITY

Not supported in Carbon. Not available in Carbon.


© 2000 Apple Computer, Inc. (Last Updated 6/30/2000)