return 0;
}
+#ifdef __linux__
static int get_nprocs(const uid_t uid)
{
int nprocs = 0;
proc_close_processes(proc);
return nprocs;
}
+#endif
static const char *get_pwd_method(const char *str, const char **next, unsigned int *sz)
{
#endif
break;
case COL_NPROCS:
+#ifdef __linux__
+
xasprintf(&user->nprocs, "%d", get_nprocs(pwd->pw_uid));
+#endif
break;
default:
/* something went very wrong here */
#endif
break;
case COL_NPROCS:
+#ifdef __linux__
+
rc = scols_line_set_data(ln, n, user->nprocs);
+#endif
break;
default:
/* something went very wrong here */
} else if (ncolumns == 2) {
/* default columns */
+#ifdef __linux__
add_column(columns, ncolumns++, COL_NPROCS);
+#endif
add_column(columns, ncolumns++, COL_PWDLOCK);
add_column(columns, ncolumns++, COL_PWDDENY);
add_column(columns, ncolumns++, COL_LAST_LOGIN);