aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--USER/USER.xs18
1 files changed, 17 insertions, 1 deletions
diff --git a/USER/USER.xs b/USER/USER.xs
index 9a64433..5505d95 100644
--- a/USER/USER.xs
+++ b/USER/USER.xs
@@ -146,7 +146,23 @@ Admin_groups_enumerate_full(self, pattern)
g_ptr_array_free(accounts, TRUE);
OUTPUT:
RETVAL
-
+
+AV *
+Admin_get_user_shells(self)
+ USER::ADMIN *self
+ CODE:
+ int i = 0;
+ const char *shell;
+ RETVAL = (AV*)sv_2mortal((SV*)newAV());
+ setusershell();
+ while ((shell = getusershell()) != NULL) {
+ av_store(RETVAL, i, newSVpv(shell, 0));
+ i++;
+ }
+ endusershell();
+ OUTPUT:
+ RETVAL
+
MODULE = USER PACKAGE = USER::ENT PREFIX = Ent_
USER::ENT *