Using Lua 4.0.1 I wish to dynamically revector the Lua functions write, writeto, read and readfrom so that the original function is called when not using stdin/stdout but calls my function when using stdin/stdout. Can anyone help? DB