scanf.c
上传用户:super_houu
上传日期:2008-09-21
资源大小:4099k
文件大小:1k
- /*
- * Paradigm C/C++ Run-Time Library - Version 5.0
- *
- * Copyright (c) 1998 Paradigm Systems. All rights reserved.
- * Portions Copyright (c) 1996 Borland International.
- *
- * $Revision: 3 $
- * $Workfile: scanf.c $
- *
- * function(s)
- * scanf - gets formatted input from stdin
- */
- #include "Config.h" // Global Configuration - do not remove!
- #if defined(_DEBUG) || defined(D_RELEASE_TRACE_ENABLED) // ZKR GL051004
- #include "CpuV186tserio.h"
- #include <stdarg.h>
- #include <stdio.h>
- #undef ungetc /* remove the macro version */
- /*---------------------------------------------------------------------*
- Name scanf - gets formatted input from stdin
- Usage int scanf(const char *format[, argument ...])
- Prototype in stdio.h
- Description gets formatted input from stdin
- Return value number of fields scanned and stored. scanf returns EOF
- if an attempt is made to read at end-of-file
- *---------------------------------------------------------------------*/
- #pragma codeseg _TEXT "CODE"
- int _RTLENTRY _FARFUNC scanf(const char *fmt, ...)
- {
- char zString[RECEIVE_STRING_SIZE_LIMIT];
- gets (zString);
- return vsscanf(zString,fmt,_va_ptr);
- }
- #endif // #if defined(_DEBUG) || defined(D_RELEASE_TRACE_ENABLED) // ZKR GL051004