/*- * Copyright (c) 1990, 1993 * The Regents of the University of California. All rights reserved. * * This code is derived from software contributed to Berkeley by * Chris Torek. * * %sccs.include.redist.c% */ #if defined(LIBC_SCCS) && !defined(lint) static char sccsid[] = "@(#)scanf.c 8.1 (Berkeley) 06/04/93"; #endif /* LIBC_SCCS and not lint */ #include #if __STDC__ #include #else #include #endif #if __STDC__ scanf(char const *fmt, ...) #else scanf(fmt, va_alist) char *fmt; va_dcl #endif { int ret; va_list ap; #if __STDC__ va_start(ap, fmt); #else va_start(ap); #endif ret = __svfscanf(stdin, fmt, ap); va_end(ap); return (ret); }