home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / octa21fs.zip / octave / kpathsea / tex-hush.c < prev    next >
C/C++ Source or Header  |  2000-01-15  |  1KB  |  40 lines

  1. /* tex-hush.c: are we suppressing warnings?
  2.  
  3. Copyright (C) 1996 Karl Berry.
  4.  
  5. This program is free software; you can redistribute it and/or modify
  6. it under the terms of the GNU General Public License as published by
  7. the Free Software Foundation; either version 2, or (at your option)
  8. any later version.
  9.  
  10. This program is distributed in the hope that it will be useful,
  11. but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  13. GNU General Public License for more details.
  14.  
  15. You should have received a copy of the GNU General Public License
  16. along with this program; if not, write to the Free Software
  17. Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
  18.  
  19. #include <kpathsea/config.h>
  20.  
  21. #include <kpathsea/pathsearch.h>
  22. #include <kpathsea/tex-hush.h>
  23. #include <kpathsea/variable.h>
  24.  
  25. boolean
  26. kpse_tex_hush P1C(const_string, what)
  27. {
  28.   string h;
  29.   string hush = kpse_var_value ("TEX_HUSH");
  30.   if (hush) {
  31.     for (h = kpse_path_element (hush); h; h = kpse_path_element (NULL)) {
  32.       /* Don't do anything special with empty elements.  */
  33.       if (STREQ (h, what) || STREQ (h, "all"))
  34.         return true;
  35.     }
  36.   }
  37.   
  38.   return false;
  39. }
  40.