-#ifdef HAVE_RUN_DIR
- /* on some dists rundir gets purged on startup. so we need to recreate it. */
-
- if (stat(ctdl_run_dir, &filestats) == -1) {
-#ifdef HAVE_GETPWUID_R
-#ifdef SOLARIS_GETPWUID
- pwp = getpwuid_r(ctdluid, &pw, pwbuf, sizeof(pwbuf));
-#else // SOLARIS_GETPWUID
- getpwuid_r(ctdluid, &pw, pwbuf, sizeof(pwbuf), &pwp);
-#endif // SOLARIS_GETPWUID
-#else // HAVE_GETPWUID_R
- pwp = NULL;
-#endif // HAVE_GETPWUID_R
-
- if ((mkdir(ctdl_run_dir, 0755) != 0) && (errno != EEXIST)) {
- syslog(LOG_ERR, "main: unable to create run directory [%s]: %m", ctdl_run_dir);
- }
+ if ((mkdir(ctdl_run_dir, 0755) != 0) && (errno != EEXIST)) {
+ syslog(LOG_ERR, "main: unable to create run directory [%s]: %m", ctdl_run_dir);
+ }