summaryrefslogtreecommitdiff
path: root/usr/src/lib/libmail/common/notifyu.c
diff options
context:
space:
mode:
authorToomas Soome <tsoome@me.com>2018-11-22 12:01:51 +0200
committerToomas Soome <tsoome@me.com>2020-01-09 10:28:51 +0200
commit7e536b59b5c21c385f301967cb3b7e31d307d131 (patch)
treeadc4a20f0779330fa5bdf362994d9c589946aaf9 /usr/src/lib/libmail/common/notifyu.c
parent0639c0edfe5fac11628e478be2a3b2d88556fc80 (diff)
downloadillumos-gate-7e536b59b5c21c385f301967cb3b7e31d307d131.tar.gz
11982 libmail: cast between incompatible function types
Reviewed by: Andy Fiddaman <andy@omniosce.org> Approved by: Dan McDonald <danmcd@joyent.com>
Diffstat (limited to 'usr/src/lib/libmail/common/notifyu.c')
-rw-r--r--usr/src/lib/libmail/common/notifyu.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/usr/src/lib/libmail/common/notifyu.c b/usr/src/lib/libmail/common/notifyu.c
index 9d4b7d4694..1cbeb583fc 100644
--- a/usr/src/lib/libmail/common/notifyu.c
+++ b/usr/src/lib/libmail/common/notifyu.c
@@ -25,9 +25,7 @@
*/
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-#pragma ident "%Z%%M% %I% %E% SMI"
+/* All Rights Reserved */
#include "libmail.h"
#include <sys/types.h>
@@ -41,12 +39,10 @@ typedef void (*SIG_PF) (int);
#include <unistd.h>
#include <signal.h>
-static SIG_PF catcher(void);
-
-static SIG_PF catcher(void)
+static void
+catcher(int arg __unused)
{
/* do nothing, but allow the write() to break */
- return (0);
}
void
@@ -77,7 +73,7 @@ notify(char *user, char *msg, int check_mesg_y, char *etcdir)
(void) sprintf(dev, "%s/dev/%s", etcdir, tty);
/* break out if write() to the tty hangs */
- old = (SIG_PF)signal(SIGALRM, (SIG_PF)catcher);
+ old = (SIG_PF)signal(SIGALRM, catcher);
oldalarm = alarm(300);
/* check if device is really a tty */