summaryrefslogtreecommitdiff
path: root/usr/src/cmd/cron/crontab.c
diff options
context:
space:
mode:
authorJerry Jelinek <jerry.jelinek@joyent.com>2019-07-09 11:44:10 +0000
committerJerry Jelinek <jerry.jelinek@joyent.com>2019-07-09 11:44:10 +0000
commita6fadc5b8524bc403c026a620fd325448da8f28f (patch)
treebc8617e28b65fa4ec413fc13be6200eb3225b035 /usr/src/cmd/cron/crontab.c
parentb322ba367cdb75882f1cede5a8b22c7fd17ced94 (diff)
parent6f2b04a2ce785423fe988216ae694366499884b2 (diff)
downloadillumos-joyent-a6fadc5b8524bc403c026a620fd325448da8f28f.tar.gz
[illumos-gate merge]
commit 6f2b04a2ce785423fe988216ae694366499884b2 11304 cmd-crypto: NULL pointer errors commit 19803d096124c0f1ca62906eb328234556bfad35 11303 cron: NULL pointer errors commit a3ab7e857d66d206fcfc56f9a628266bd25a7bd0 11319 devfsadm: NULL pointer errors commit 1fbb7a7c3b62c369349ec1774806ed321e4f6119 11332 Regression: 11184 causes kernel hang during boot on CPUs without ARAT commit 62efa0e74455f83caa0fa7df8926a5ec9656b3ce 11213 tem: partially support CSI [ 38 and 48 sequences with smaller depths commit 023a3eeed3dc3724c83a2c43af879ce1719b2e32 11324 expr: NULL pointer errors commit c7cb3c8ba9fee2d8fc1a3ba06662ed84679fbd66 11323 syseventd: NULL pointer errors commit 1a80a7c52201c03ace9f85bdb77b768062b06136 11322 dfs.cmds: NULL pointer errors commit 8f32bfdc833ff8990921fa7b28a4d6bd970ef98f 11290 captoinfo: NULL pointer errors commit 84bdd7fe0904e8a6527441769054b6bc92a1ffe0 10329 Remove scsi_vhci_f_asym_sun (StorEdge T3 support) commit f9d4be10f65289547fa67ea8d1a3de54596b3ba1 11300 cpustat: NULL pointer errors
Diffstat (limited to 'usr/src/cmd/cron/crontab.c')
-rw-r--r--usr/src/cmd/cron/crontab.c20
1 files changed, 8 insertions, 12 deletions
diff --git a/usr/src/cmd/cron/crontab.c b/usr/src/cmd/cron/crontab.c
index cdb4e1e394..c6f1673ad8 100644
--- a/usr/src/cmd/cron/crontab.c
+++ b/usr/src/cmd/cron/crontab.c
@@ -23,7 +23,7 @@
* Use is subject to license terms.
*/
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
+/* All Rights Reserved */
#include <sys/types.h>
@@ -427,8 +427,7 @@ main(int argc, char **argv)
}
static void
-copycron(fp)
-FILE *fp;
+copycron(FILE *fp)
{
FILE *tfp;
char pid[6], *tnam_end;
@@ -468,7 +467,7 @@ FILE *fp;
strncpy(buf, &line[cursor + strlen(ENV_TZ)],
sizeof (buf));
if ((x = strchr(buf, '\n')) != NULL)
- *x = NULL;
+ *x = '\0';
if (isvalid_tz(buf, NULL, _VTZ_ALL)) {
goto cont;
@@ -484,7 +483,7 @@ FILE *fp;
strncpy(buf, &line[cursor + strlen(ENV_SHELL)],
sizeof (buf));
if ((x = strchr(buf, '\n')) != NULL)
- *x = NULL;
+ *x = '\0';
if (isvalid_shell(buf)) {
goto cont;
@@ -500,7 +499,7 @@ FILE *fp;
strncpy(buf, &line[cursor + strlen(ENV_HOME)],
sizeof (buf));
if ((x = strchr(buf, '\n')) != NULL)
- *x = NULL;
+ *x = '\0';
if (chdir(buf) == 0) {
goto cont;
} else {
@@ -546,8 +545,7 @@ cont:
}
static int
-next_field(lower, upper)
-int lower, upper;
+next_field(int lower, int upper)
{
int num, num2;
@@ -605,8 +603,7 @@ int lower, upper;
}
static void
-cerror(msg)
-char *msg;
+cerror(char *msg)
{
fprintf(stderr, gettext("%scrontab: error on previous line; %s\n"),
line, msg);
@@ -622,8 +619,7 @@ catch(int x)
}
static void
-crabort(msg)
-char *msg;
+crabort(char *msg)
{
int sverrno;