warn.html 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. <html>
  2. <head>
  3. <title>warn</title>
  4. <body bgcolor=#ffffff>
  5. <h2 align=center>warn</h2>
  6. <h4 align=center>OS/161 Reference Manual</h4>
  7. <h3>Name</h3>
  8. warn, warnx, vwarn, vwarnx - print warning messages
  9. <h3>Library</h3>
  10. Standard C Library (libc, -lc)
  11. <h3>Synopsis</h3>
  12. #include &lt;err.h&gt;<br>
  13. <br>
  14. void<br>
  15. warn(const char *<em>format</em>, ...);<br>
  16. <br>
  17. void<br>
  18. warnx(const char *<em>format</em>, ...);<br>
  19. <br>
  20. void<br>
  21. vwarn(const char *<em>format</em>, va_list);<br>
  22. <br>
  23. void<br>
  24. vwarnx(const char *<em>format</em>, va_list);<br>
  25. <h3>Description</h3>
  26. The warn, warnx, vwarn, and vwarnx functions print warning messages to
  27. the standard error stream.
  28. <p>
  29. warnx prints the name of the program, a colon, the text generated by
  30. passing <em>format</em> and subsequent args through
  31. <A HREF=printf.html>printf</A>, and a newline.
  32. <p>
  33. warn prints the same thing, except that a colon and the error string
  34. for the current error (obtained by calling
  35. <A HREF=strerror.html>strerror</A> on
  36. <A HREF=../syscall/errno.html>errno</A>) are printed prior to the
  37. newline.
  38. <p>
  39. vwarnx and vwarn are the same as warnx and warn respectively, except
  40. that the additional arguments for printf are taken to have been
  41. already packaged up in a va_list by use of the
  42. <A HREF=stdarg.html>stdarg</A> facility.
  43. <p>
  44. <h3>See Also</h3>
  45. <A HREF=err.html>err</A>
  46. </body>
  47. </html>