=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/talk/get_names.c,v retrieving revision 1.13 retrieving revision 1.14 diff -c -r1.13 -r1.14 *** src/usr.bin/talk/get_names.c 2003/07/10 00:06:51 1.13 --- src/usr.bin/talk/get_names.c 2003/10/01 06:32:44 1.14 *************** *** 1,4 **** ! /* $OpenBSD: get_names.c,v 1.13 2003/07/10 00:06:51 david Exp $ */ /* $NetBSD: get_names.c,v 1.4 1994/12/09 02:14:16 jtc Exp $ */ /* --- 1,4 ---- ! /* $OpenBSD: get_names.c,v 1.14 2003/10/01 06:32:44 deraadt Exp $ */ /* $NetBSD: get_names.c,v 1.4 1994/12/09 02:14:16 jtc Exp $ */ /* *************** *** 34,40 **** #if 0 static char sccsid[] = "@(#)get_names.c 8.1 (Berkeley) 6/6/93"; #endif ! static char rcsid[] = "$OpenBSD: get_names.c,v 1.13 2003/07/10 00:06:51 david Exp $"; #endif /* not lint */ #include "talk.h" --- 34,40 ---- #if 0 static char sccsid[] = "@(#)get_names.c 8.1 (Berkeley) 6/6/93"; #endif ! static char rcsid[] = "$OpenBSD: get_names.c,v 1.14 2003/10/01 06:32:44 deraadt Exp $"; #endif /* not lint */ #include "talk.h" *************** *** 93,98 **** --- 93,100 ---- my_machine_name = hostname; /* check for, and strip out, the machine name of the target */ names = strdup(argv[1]); + if (names == NULL) + errx(1, "out of memory"); for (cp = names; *cp && !strchr("@:!.", *cp); cp++) ; if (*cp == '\0') {