]> andersk Git - moira.git/blobdiff - gen/passwd.dc
added definition of NULL
[moira.git] / gen / passwd.dc
index c3984dab024ba7f21e54875ab86460b59e99271d..e1dedbf37fce104e7c4292dc5e3fa93b8f4fa43c 100644 (file)
@@ -2,8 +2,13 @@
  *
  * This generates a master /etc/passwd containing all active (status != 0)
  * accounts.
+ *
+ *  (c) Copyright 1988 by the Massachusetts Institute of Technology.
+ *  For copying and distribution information, please see the file
+ *  <mit-copyright.h>.
  */
 
+#include <mit-copyright.h>
 #include <stdio.h>
 #include <sms.h>
 #include <sys/types.h>
@@ -23,11 +28,13 @@ char **argv;
     char *outf, outft[64];
     struct stat sb;
 ##  char login[9], shell[33], fullname[33], oa[17], op[13], hp[17], *filetime;
+##  char nickname[17];
 ##  int uid, error, flag;
     int ingerr();
 
     IIseterr(ingerr);
 ##  ingres sms
+##  set lockmode session where level = table
 
     if (argc == 2) {
        if (stat(argv[1], &sb) == 0) {
@@ -53,21 +60,21 @@ char **argv;
        outf = NULL;
     }
 
-##  set lockmode on users where readlock = nolock
-
 ##  range of u is users
 ##  retrieve (login = u.#login, uid = u.#uid, shell = u.#shell,
 ##           fullname = u.#fullname, oa = u.office_addr,
+##           nickname = u.#nickname,
 ##           op = u.office_phone, hp = u.home_phone)
 ##     where u.status = 1 {
            strtrim(login);
            strtrim(fullname);
+           strtrim(nickname);
            strtrim(oa);
            strtrim(op);
            strtrim(hp);
            strtrim(shell);
-           fprintf(out, "%s:*:%d:101:%s,%s,%s,%s:/mit/%s:%s\n",
-                   login, uid, fullname, oa, op, hp, login, shell);
+           fprintf(out, "%s:*:%d:101:%s,%s,%s,%s,%s:/mit/%s:%s\n",
+                   login, uid, fullname, nickname, oa, op, hp, login, shell);
 ##  }
 ##  inquire_equel(error = "errorno")
     if (error)  {
This page took 0.037781 seconds and 4 git commands to generate.