Fixed a warning (missing type cast)
[tangerine.git] / rom / exec / rawputchar.c
blob0baad7aba0219fabc65196a85fabcdc9f8fead89
1 /*
2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
3 $Id$
5 Desc: Emit one character via raw IO
6 Lang: english
7 */
8 #include <unistd.h>
10 /*****i***********************************************************************
12 NAME */
13 #include <proto/exec.h>
15 AROS_LH1(void, RawPutChar,
17 /* SYNOPSIS */
18 AROS_LHA(UBYTE, chr, D0),
20 /* LOCATION */
21 struct ExecBase *, SysBase, 86, Exec)
23 /* FUNCTION
24 Emits a single character.
26 INPUTS
27 chr - The character to emit
29 RESULT
30 None.
32 NOTES
33 This function is for very low level debugging only.
35 EXAMPLE
37 BUGS
39 SEE ALSO
40 RawIOInit(), RawPutChar(), RawMayGetChar()
42 INTERNALS
44 *****************************************************************************/
46 AROS_LIBFUNC_INIT
47 AROS_LIBBASE_EXT_DECL(struct ExecBase *,SysBase)
49 /* Don't write 0 bytes */
50 if (chr)
52 /* Write char to stderr */
53 write (STDERR_FILENO, &chr, 1);
55 /* Make sure it makes it to the user. Slow but save. */
56 fsync (STDERR_FILENO);
59 AROS_LIBFUNC_EXIT
60 } /* RawPutChar */