/mandos/trunk

To get this branch, use:
bzr branch http://bzr.recompile.se/loggerhead/mandos/trunk

« back to all changes in this revision

Viewing changes to plugins.d/mandos-client.c

  • Committer: Teddy Hogeborn
  • Date: 2016-02-28 20:26:27 UTC
  • Revision ID: teddy@recompile.se-20160228202627-vls5dia6repq6ks2
Depend on the GNU C Library 2.16 or later 

* INSTALL: Document dependency.
* plugin-runner.c: Remove #ifdefs for scandirat() and adding of
                   -Wsign-conversion for FD_SET, FD_CLR, and FD_ISSET.
* plugins.d/mandos-client.c: - '' -

Show diffs side-by-side

added added

removed removed

Lines of Context:
1914
1914
      return;
1915
1915
    }
1916
1916
  }
1917
 
#ifdef __GLIBC__
1918
 
#if __GLIBC_PREREQ(2, 15)
1919
1917
  int numhooks = scandirat(hookdir_fd, ".", &direntries,
1920
1918
                           runnable_hook, alphasort);
1921
 
#else  /* not __GLIBC_PREREQ(2, 15) */
1922
 
  int numhooks = scandir(hookdir, &direntries, runnable_hook,
1923
 
                         alphasort);
1924
 
#endif  /* not __GLIBC_PREREQ(2, 15) */
1925
 
#else   /* not __GLIBC__ */
1926
 
  int numhooks = scandir(hookdir, &direntries, runnable_hook,
1927
 
                         alphasort);
1928
 
#endif  /* not __GLIBC__ */
1929
1919
  if(numhooks == -1){
1930
1920
    perror_plus("scandir");
1931
1921
    return;
3054
3044
    if(tempdir_fd == -1){
3055
3045
      perror_plus("open");
3056
3046
    } else {
3057
 
#ifdef __GLIBC__
3058
 
#if __GLIBC_PREREQ(2, 15)
3059
3047
      int numentries = scandirat(tempdir_fd, ".", &direntries,
3060
3048
                                 notdotentries, alphasort);
3061
 
#else  /* not __GLIBC_PREREQ(2, 15) */
3062
 
      int numentries = scandir(tempdir, &direntries, notdotentries,
3063
 
                               alphasort);
3064
 
#endif  /* not __GLIBC_PREREQ(2, 15) */
3065
 
#else   /* not __GLIBC__ */
3066
 
      int numentries = scandir(tempdir, &direntries, notdotentries,
3067
 
                               alphasort);
3068
 
#endif  /* not __GLIBC__ */
3069
3049
      if(numentries >= 0){
3070
3050
        for(int i = 0; i < numentries; i++){
3071
3051
          ret = unlinkat(tempdir_fd, direntries[i]->d_name, 0);