NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

bin/49714: Change NULL in EV_SET to 0.



>Number:         49714
>Category:       bin
>Synopsis:       Change NULL in EV_SET to 0.
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    bin-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Mar 04 12:10:00 +0000 2015
>Originator:     Henning Petersen
>Release:        NetBSD-current
>Organization:
>Environment:
>Description:
In macro EV_SET last argument is intptr_t it has to be changed from NULL
to 0. 
>How-To-Repeat:

>Fix:
diff -u -p -r1.3 pwait.c
--- usr.bin/pwait/pwait.c	3 Mar 2015 19:59:48 -0000	1.3
+++ usr.bin/pwait/pwait.c	4 Mar 2015 11:47:02 -0000
@@ -143,7 +143,7 @@ main(int argc, char *argv[])
 				duplicate = 1;
 		if (!duplicate) {
 			EV_SET(e + nleft, (uintptr_t)pid, EVFILT_PROC, EV_ADD,
-			    NOTE_EXIT, 0, NULL);
+			    NOTE_EXIT, 0, 0);
 			if (kevent(kq, e + nleft, 1, NULL, 0, NULL) == -1)
 				warn("%jd", (intmax_t)pid);
 			else



Home | Main Index | Thread Index | Old Index