Sun Feb 23 07:49:04 2014 UTC ()
Provide a prototype for xputchar


(martin)
diff -r1.3 -r1.4 src/sys/arch/emips/stand/common/printf.c

cvs diff -r1.3 -r1.4 src/sys/arch/emips/stand/common/printf.c (expand / switch to unified diff)

--- src/sys/arch/emips/stand/common/printf.c 2011/07/21 11:04:24 1.3
+++ src/sys/arch/emips/stand/common/printf.c 2014/02/23 07:49:04 1.4
@@ -1,35 +1,37 @@ @@ -1,35 +1,37 @@
1/* $NetBSD: printf.c,v 1.3 2011/07/21 11:04:24 joerg Exp $ */ 1/* $NetBSD: printf.c,v 1.4 2014/02/23 07:49:04 martin Exp $ */
2/*- 2/*-
3 * Copyright (c) 1998 Robert Nordier 3 * Copyright (c) 1998 Robert Nordier
4 * All rights reserved. 4 * All rights reserved.
5 * Copyright (c) 2006 M. Warner Losh 5 * Copyright (c) 2006 M. Warner Losh
6 * All rights reserved. 6 * All rights reserved.
7 * 7 *
8 * Redistribution and use in source and binary forms are freely 8 * Redistribution and use in source and binary forms are freely
9 * permitted provided that the above copyright notice and this 9 * permitted provided that the above copyright notice and this
10 * paragraph and the following disclaimer are duplicated in all 10 * paragraph and the following disclaimer are duplicated in all
11 * such forms. 11 * such forms.
12 * 12 *
13 * This software is provided "AS IS" and without any express or 13 * This software is provided "AS IS" and without any express or
14 * implied warranties, including, without limitation, the implied 14 * implied warranties, including, without limitation, the implied
15 * warranties of merchantability and fitness for a particular 15 * warranties of merchantability and fitness for a particular
16 * purpose. 16 * purpose.
17 * 17 *
18 * $FreeBSD: src/sys/boot/mips/emips/libemips/printf.c,v 1.2 2006/10/20 09:12:05 imp Exp $ 18 * $FreeBSD: src/sys/boot/mips/emips/libemips/printf.c,v 1.2 2006/10/20 09:12:05 imp Exp $
19 */ 19 */
20 20
21#include <lib/libsa/stand.h> 21#include <lib/libsa/stand.h>
22 22
 23void xputchar(int);
 24
23void 25void
24xputchar(int ch) 26xputchar(int ch)
25{ 27{
26 if (ch == '\n') 28 if (ch == '\n')
27 putchar('\r'); 29 putchar('\r');
28 putchar(ch); 30 putchar(ch);
29} 31}
30 32
31void 33void
32printf(const char *fmt,...) 34printf(const char *fmt,...)
33{ 35{
34 va_list ap; 36 va_list ap;
35 const char *hex = "0123456789abcdef"; 37 const char *hex = "0123456789abcdef";