Exemplo n.º 1
0
int lib_rawprintf(const char *fmt, ...)
{
  va_list ap;
  int     ret;

  va_start(ap, fmt);
  ret= lib_rawvprintf(fmt, ap);
  va_end(ap);
  return ret;
}
Exemplo n.º 2
0
int printf(const char *fmt, ...)
{
  va_list ap;
  int     ret;

  va_start(ap, fmt);
#if CONFIG_NFILE_STREAMS > 0
  ret = vfprintf(stdout, fmt, ap);
#elif CONFIG_NFILE_DESCRIPTORS > 0
  ret = lib_rawvprintf(fmt, ap);
#elif defined(CONFIG_ARCH_LOWPUTC)
  ret = lib_lowvprintf(fmt, ap);
#else
# ifdef CONFIG_CPP_HAVE_WARNING
#   warning "printf has no data sink"
# endif
  ret = 0;
#endif
  va_end(ap);

  return ret;
}