[BACK]Return to manpath.c CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/manpath.c between version 1.25 and 1.27

version 1.25, 2015/05/07 12:08:13 version 1.27, 2015/10/11 21:12:55
Line 21 
Line 21 
 #include <sys/stat.h>  #include <sys/stat.h>
   
 #include <ctype.h>  #include <ctype.h>
   #include <err.h>
 #include <limits.h>  #include <limits.h>
 #include <stdio.h>  #include <stdio.h>
 #include <stdlib.h>  #include <stdlib.h>
Line 29 
Line 30 
 #include "mandoc_aux.h"  #include "mandoc_aux.h"
 #include "manconf.h"  #include "manconf.h"
   
   #if !HAVE_MANPATH
 static  void     manconf_file(struct manconf *, const char *);  static  void     manconf_file(struct manconf *, const char *);
   #endif
 static  void     manpath_add(struct manpaths *, const char *, int);  static  void     manpath_add(struct manpaths *, const char *, int);
 static  void     manpath_parseline(struct manpaths *, char *, int);  static  void     manpath_parseline(struct manpaths *, char *, int);
   
Line 163  manpath_add(struct manpaths *dirs, const char *dir, in
Line 166  manpath_add(struct manpaths *dirs, const char *dir, in
         size_t           i;          size_t           i;
   
         if (NULL == (cp = realpath(dir, buf))) {          if (NULL == (cp = realpath(dir, buf))) {
                 if (complain) {                  if (complain)
                         fputs("manpath: ", stderr);                          warn("manpath: %s", dir);
                         perror(dir);  
                 }  
                 return;                  return;
         }          }
   
Line 175  manpath_add(struct manpaths *dirs, const char *dir, in
Line 176  manpath_add(struct manpaths *dirs, const char *dir, in
                         return;                          return;
   
         if (stat(cp, &sb) == -1) {          if (stat(cp, &sb) == -1) {
                 if (complain) {                  if (complain)
                         fputs("manpath: ", stderr);                          warn("manpath: %s", dir);
                         perror(dir);  
                 }  
                 return;                  return;
         }          }
   
Line 203  manconf_free(struct manconf *conf)
Line 202  manconf_free(struct manconf *conf)
         free(conf->output.style);          free(conf->output.style);
 }  }
   
   #if !HAVE_MANPATH
 static void  static void
 manconf_file(struct manconf *conf, const char *file)  manconf_file(struct manconf *conf, const char *file)
 {  {
Line 263  out:
Line 263  out:
         if (*manpath_default != '\0')          if (*manpath_default != '\0')
                 manpath_parseline(&conf->manpath, manpath_default, 0);                  manpath_parseline(&conf->manpath, manpath_default, 0);
 }  }
   #endif
   
 void  void
 manconf_output(struct manoutput *conf, const char *cp)  manconf_output(struct manoutput *conf, const char *cp)

Legend:
Removed from v.1.25  
changed lines
  Added in v.1.27

CVSweb