/*@-exitarg@*/
#include "exitcodes.h"
#include "shadowlog.h"
+#include "strlcpy.h"
/*
* Global variables.
exit (E_NOPERM);
}
fflg = true;
- STRFCPY (fullnm, optarg);
+ STRLCPY(fullnm, optarg);
break;
case 'h':
if (!may_change_field ('h')) {
exit (E_NOPERM);
}
hflg = true;
- STRFCPY (homeph, optarg);
+ STRLCPY(homeph, optarg);
break;
case 'o':
if (!amroot) {
_("%s: fields too long\n"), Prog);
exit (E_NOPERM);
}
- STRFCPY (slop, optarg);
+ STRLCPY(slop, optarg);
break;
case 'r':
if (!may_change_field ('r')) {
exit (E_NOPERM);
}
rflg = true;
- STRFCPY (roomno, optarg);
+ STRLCPY(roomno, optarg);
break;
case 'R': /* no-op, handled in process_root_flag () */
break;
exit (E_NOPERM);
}
wflg = true;
- STRFCPY (workph, optarg);
+ STRLCPY(workph, optarg);
break;
default:
usage (E_USAGE);
{
char *cp; /* temporary character pointer */
char old_gecos[BUFSIZ]; /* buffer for old GECOS fields */
- STRFCPY (old_gecos, gecos);
+
+ STRLCPY(old_gecos, gecos);
/*
* Now get the full name. It is the first comma separated field in