revert between 56095 -> 55830 in arch
[AROS.git] / rom / dos / selectoutput.c
blob5f6c9091a12fb56afeeb4af16412cb1c3c8772d3
1 /*
2 Copyright © 1995-2007, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc:
6 Lang: english
7 */
8 #include <aros/debug.h>
10 #include <proto/exec.h>
11 #include "dos_intern.h"
13 /*****************************************************************************
15 NAME */
16 #include <proto/dos.h>
18 AROS_LH1(BPTR, SelectOutput,
20 /* SYNOPSIS */
21 AROS_LHA(BPTR, fh, D1),
23 /* LOCATION */
24 struct DosLibrary *, DOSBase, 50, Dos)
26 /* FUNCTION
27 Sets the current output stream returned by Output() to a new
28 value. Returns the old output stream.
30 INPUTS
31 fh - New output stream.
33 RESULT
34 Old output stream handle.
36 NOTES
38 EXAMPLE
40 BUGS
42 SEE ALSO
44 INTERNALS
46 *****************************************************************************/
48 AROS_LIBFUNC_INIT
50 BPTR old;
52 /* Get pointer to process structure */
53 struct Process *me=(struct Process *)FindTask(NULL);
55 ASSERT_VALID_PROCESS(me);
57 /* Nothing spectacular */
58 old=me->pr_COS;
59 me->pr_COS=fh;
60 return old;
61 AROS_LIBFUNC_EXIT
62 } /* SelectOutput */