Module Name: src
Committed By: christos
Date: Wed Nov 27 20:50:45 UTC 2013
Modified Files:
src/external/bsd/nvi/dist/ipc: ipc_method.c
Log Message:
CID 1132758: Unchecked return value
To generate a diff of this commit:
cvs rdiff -u -r1.4 -r1.5 src/external/bsd/nvi/dist/ipc/ipc_method.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/external/bsd/nvi/dist/ipc/ipc_method.c
diff -u src/external/bsd/nvi/dist/ipc/ipc_method.c:1.4 src/external/bsd/nvi/dist/ipc/ipc_method.c:1.5
--- src/external/bsd/nvi/dist/ipc/ipc_method.c:1.4 Wed Nov 27 12:51:04 2013
+++ src/external/bsd/nvi/dist/ipc/ipc_method.c Wed Nov 27 15:50:45 2013
@@ -1,4 +1,4 @@
-/* $NetBSD: ipc_method.c,v 1.4 2013/11/27 17:51:04 christos Exp $ */
+/* $NetBSD: ipc_method.c,v 1.5 2013/11/27 20:50:45 christos Exp $ */
/*-
* Copyright (c) 1996
* Rob Zimmermann. All rights reserved.
@@ -92,7 +92,8 @@ vi_new_window (IPVI *ipvi, IPVIWIN **ipv
char dummy;
struct iovec iov;
- socketpair(AF_LOCAL, SOCK_STREAM, 0, sockets);
+ if (socketpair(AF_LOCAL, SOCK_STREAM, 0, sockets) == -1)
+ goto alloc_err;
memset(&mh, 0, sizeof(mh));
mh.msg_namelen = 0;