summaryrefslogtreecommitdiffstats
path: root/usr.bin/at
diff options
context:
space:
mode:
authorrgrimes <rgrimes@FreeBSD.org>1995-05-30 06:41:30 +0000
committerrgrimes <rgrimes@FreeBSD.org>1995-05-30 06:41:30 +0000
commita14d555c873398b14776ca4f2c33f9c69617afb9 (patch)
tree350f6f98843363254f9afe467ae0c92d5a9d7f43 /usr.bin/at
parentf3a2b348daf9fa6063c38d2d69563f732a2f80e7 (diff)
downloadFreeBSD-src-a14d555c873398b14776ca4f2c33f9c69617afb9.zip
FreeBSD-src-a14d555c873398b14776ca4f2c33f9c69617afb9.tar.gz
Remove trailing whitespace.
Diffstat (limited to 'usr.bin/at')
-rw-r--r--usr.bin/at/at.c56
-rw-r--r--usr.bin/at/at.h2
-rw-r--r--usr.bin/at/panic.c4
-rw-r--r--usr.bin/at/panic.h2
-rw-r--r--usr.bin/at/parsetime.c8
-rw-r--r--usr.bin/at/parsetime.h2
-rw-r--r--usr.bin/at/perm.c4
-rw-r--r--usr.bin/at/perm.h2
-rw-r--r--usr.bin/at/privs.h6
9 files changed, 43 insertions, 43 deletions
diff --git a/usr.bin/at/at.c b/usr.bin/at/at.c
index 70fc6c9..d2e6e30 100644
--- a/usr.bin/at/at.c
+++ b/usr.bin/at/at.c
@@ -1,4 +1,4 @@
-/*
+/*
* at.c : Put file into atrun queue
* Copyright (C) 1993, 1994 Thomas Koenig
*
@@ -61,7 +61,7 @@
/* Macros */
-#ifndef ATJOB_DIR
+#ifndef ATJOB_DIR
#define ATJOB_DIR "/usr/spool/atjobs/"
#endif
@@ -80,7 +80,7 @@
/* File scope variables */
-static char rcsid[] = "$Id: at.c,v 1.3 1995/04/15 22:08:08 ache Exp $";
+static char rcsid[] = "$Id: at.c,v 1.4 1995/04/27 19:27:41 ache Exp $";
char *no_export[] =
{
"TERM", "TERMCAP", "DISPLAY", "_"
@@ -110,7 +110,7 @@ static void list_jobs(void);
static void sigc(int signo)
{
-/* If the user presses ^C, remove the spool file and exit
+/* If the user presses ^C, remove the spool file and exit
*/
if (fcreated)
{
@@ -149,10 +149,10 @@ static char *cwdname(void)
if (getcwd(ptr, size-1) != NULL)
return ptr;
-
+
if (errno != ERANGE)
perr("Cannot get directory");
-
+
free (ptr);
size += SIZE;
ptr = (char *) mymalloc(size);
@@ -175,7 +175,7 @@ writefile(time_t runtimer, char queue)
int ch;
mode_t cmask;
struct flock lock;
-
+
/* Install the signal handler for SIGINT; terminate after removing the
* spool file if necessary
*/
@@ -215,7 +215,7 @@ writefile(time_t runtimer, char queue)
for(i=0; i<ATJOB_MX; i++)
{
- sprintf(ppos, "%c%8lx.%2x", queue,
+ sprintf(ppos, "%c%8lx.%2x", queue,
(unsigned long) (runtimer/60), i);
for(ap=ppos; *ap != '\0'; ap ++)
if (*ap == ' ')
@@ -240,7 +240,7 @@ writefile(time_t runtimer, char queue)
*/
cmask = umask(S_IRUSR | S_IWUSR | S_IXUSR);
if ((fdes = creat(atfile, O_WRONLY)) == -1)
- perr("Cannot create atjob file");
+ perr("Cannot create atjob file");
if ((fd2 = dup(fdes)) <0)
perr("Error in dup() of job file");
@@ -256,7 +256,7 @@ writefile(time_t runtimer, char queue)
REDUCE_PRIV(DAEMON_UID, DAEMON_GID)
- /* We've successfully created the file; let's set the flag so it
+ /* We've successfully created the file; let's set the flag so it
* gets removed in case of an interrupt or error.
*/
fcreated = 1;
@@ -278,7 +278,7 @@ writefile(time_t runtimer, char queue)
if (mailname == NULL)
mailname = getenv("LOGNAME");
- if ((mailname == NULL) || (mailname[0] == '\0')
+ if ((mailname == NULL) || (mailname[0] == '\0')
|| (strlen(mailname) > 8) || (getpwnam(mailname)==NULL))
{
pass_entry = getpwuid(getuid());
@@ -317,7 +317,7 @@ writefile(time_t runtimer, char queue)
for (i=0; i<sizeof(no_export)/sizeof(no_export[0]); i++)
{
export = export
- && (strncmp(*atenv, no_export[i],
+ && (strncmp(*atenv, no_export[i],
(size_t) (eqp-*atenv)) != 0);
}
eqp++;
@@ -334,16 +334,16 @@ writefile(time_t runtimer, char queue)
{
if (*ap != '/' && !isalnum(*ap))
fputc('\\', fp);
-
+
fputc(*ap, fp);
}
}
fputs("; export ", fp);
fwrite(*atenv, sizeof(char), eqp-*atenv -1, fp);
fputc('\n', fp);
-
+
}
- }
+ }
/* Cd to the directory at the time and write out all the
* commands the user supplies from stdin.
*/
@@ -356,7 +356,7 @@ writefile(time_t runtimer, char queue)
{
if (*ap != '/' && !isalnum(*ap))
fputc('\\', fp);
-
+
fputc(*ap, fp);
}
}
@@ -372,7 +372,7 @@ writefile(time_t runtimer, char queue)
fprintf(fp, "\n");
if (ferror(fp))
panic("Output error");
-
+
if (ferror(stdin))
panic("Input error");
@@ -391,7 +391,7 @@ writefile(time_t runtimer, char queue)
static void
list_jobs()
{
- /* List all a user's jobs in the queue, by looping through ATJOB_DIR,
+ /* List all a user's jobs in the queue, by looping through ATJOB_DIR,
* or everybody's if we are root
*/
struct passwd *pw;
@@ -413,12 +413,12 @@ list_jobs()
if ((spool = opendir(".")) == NULL)
perr("Cannot open " ATJOB_DIR);
- /* Loop over every file in the directory
+ /* Loop over every file in the directory
*/
while((dirent = readdir(spool)) != NULL) {
if (stat(dirent->d_name, &buf) != 0)
perr("Cannot stat in " ATJOB_DIR);
-
+
/* See it's a regular file and has its x bit turned on and
* is the user's
*/
@@ -442,11 +442,11 @@ list_jobs()
}
pw = getpwuid(buf.st_uid);
- printf("%s\t%s\t%c%s\t%s\n",
- timestr,
- pw ? pw->pw_name : "???",
- queue,
- (S_IXUSR & buf.st_mode) ? "":"(done)",
+ printf("%s\t%s\t%c%s\t%s\n",
+ timestr,
+ pw ? pw->pw_name : "???",
+ queue,
+ (S_IXUSR & buf.st_mode) ? "":"(done)",
dirent->d_name);
}
PRIV_END
@@ -464,7 +464,7 @@ delete_jobs(int argc, char **argv)
if (chdir(ATJOB_DIR) != 0)
perr("Cannot change to " ATJOB_DIR);
-
+
for (i=optind; i < argc; i++) {
if (stat(argv[i], &buf) != 0) {
perr(argv[i]);
@@ -550,7 +550,7 @@ main(int argc, char **argv)
case 'f':
atinput = optarg;
break;
-
+
case 'q': /* specify queue */
if (strlen(optarg) > 1)
usage();
@@ -643,7 +643,7 @@ main(int argc, char **argv)
timer = parsetime(argc, argv);
else
timer = time(NULL);
-
+
if (atverify)
{
struct tm *tm = localtime(&timer);
diff --git a/usr.bin/at/at.h b/usr.bin/at/at.h
index 1efd316..4a5a5e5 100644
--- a/usr.bin/at/at.h
+++ b/usr.bin/at/at.h
@@ -1,4 +1,4 @@
-/*
+/*
* at.h - header for at(1)
* Copyright (C) 1993 Thomas Koenig
*
diff --git a/usr.bin/at/panic.c b/usr.bin/at/panic.c
index 9f96f71..9d21e09 100644
--- a/usr.bin/at/panic.c
+++ b/usr.bin/at/panic.c
@@ -1,4 +1,4 @@
-/*
+/*
* panic.c - terminate fast in case of error
* Copyright (C) 1993 Thomas Koenig
*
@@ -37,7 +37,7 @@
/* File scope variables */
-static char rcsid[] = "$Id: panic.c,v 1.1 1994/05/10 18:23:08 kernel Exp $";
+static char rcsid[] = "$Id: panic.c,v 1.2 1995/04/12 02:42:32 ache Exp $";
/* External variables */
diff --git a/usr.bin/at/panic.h b/usr.bin/at/panic.h
index 7f82f2d..6172895 100644
--- a/usr.bin/at/panic.h
+++ b/usr.bin/at/panic.h
@@ -1,4 +1,4 @@
-/*
+/*
* panic.h - header for at(1)
* Copyright (C) 1993 Thomas Koenig
*
diff --git a/usr.bin/at/parsetime.c b/usr.bin/at/parsetime.c
index d73149a..867893c 100644
--- a/usr.bin/at/parsetime.c
+++ b/usr.bin/at/parsetime.c
@@ -1,4 +1,4 @@
-/*
+/*
* parsetime.c - parse time for at(1)
* Copyright (C) 1993, 1994 Thomas Koenig
*
@@ -130,7 +130,7 @@ static size_t sc_len; /* scanner - lenght of token buffer */
static int sc_tokid; /* scanner - token id */
static int sc_tokplur; /* scanner - is token plural? */
-static char rcsid[] = "$Id: parsetime.c,v 1.1 1994/05/10 18:23:08 kernel Exp $";
+static char rcsid[] = "$Id: parsetime.c,v 1.3 1995/04/12 02:42:35 ache Exp $";
/* Local functions */
@@ -246,7 +246,7 @@ plonk(int tok)
} /* plonk */
-/*
+/*
* expect() gets a token and dies most horribly if it's not the token we want
*/
static void
@@ -417,7 +417,7 @@ assign_date(struct tm *tm, long mday, long mon, long year)
} /* assign_date */
-/*
+/*
* month() picks apart a month specification
*
* /[<month> NUMBER [NUMBER]] \
diff --git a/usr.bin/at/parsetime.h b/usr.bin/at/parsetime.h
index 4696e82..6bf3dfc 100644
--- a/usr.bin/at/parsetime.h
+++ b/usr.bin/at/parsetime.h
@@ -1,4 +1,4 @@
-/*
+/*
* at.h - header for at(1)
* Copyright (C) 1993 Thomas Koenig
*
diff --git a/usr.bin/at/perm.c b/usr.bin/at/perm.c
index d2c8d02..078af59 100644
--- a/usr.bin/at/perm.c
+++ b/usr.bin/at/perm.c
@@ -1,4 +1,4 @@
-/*
+/*
* perm.c - check user permission for at(1)
* Copyright (C) 1994 Thomas Koenig
*
@@ -48,7 +48,7 @@
/* File scope variables */
-static char rcsid[] = "$Id: perm.c,v 1.1 1994/05/10 18:23:08 kernel Exp $";
+static char rcsid[] = "$Id: perm.c,v 1.1 1995/04/12 02:42:37 ache Exp $";
/* Function declarations */
diff --git a/usr.bin/at/perm.h b/usr.bin/at/perm.h
index a71e11c..b7e02c8 100644
--- a/usr.bin/at/perm.h
+++ b/usr.bin/at/perm.h
@@ -1,4 +1,4 @@
-/*
+/*
* perm.h - header for at(1)
* Copyright (C) 1994 Thomas Koenig
*
diff --git a/usr.bin/at/privs.h b/usr.bin/at/privs.h
index 2fcaf10..f8520661 100644
--- a/usr.bin/at/privs.h
+++ b/usr.bin/at/privs.h
@@ -1,5 +1,5 @@
-/*
- * privs.h - header for privileged operations
+/*
+ * privs.h - header for privileged operations
* Copyright (C) 1993 Thomas Koenig
*
* This program is free software; you can redistribute it and/or modify
@@ -62,7 +62,7 @@ extern
#endif
uid_t real_uid, effective_uid;
-#ifndef MAIN
+#ifndef MAIN
extern
#endif
gid_t real_gid, effective_gid;
OpenPOWER on IntegriCloud