diff options
author | Ricardo Mestre <mestre@cvs.openbsd.org> | 2016-03-29 14:53:28 +0000 |
---|---|---|
committer | Ricardo Mestre <mestre@cvs.openbsd.org> | 2016-03-29 14:53:28 +0000 |
commit | 78e3eda7d2483cc50678c2fd8ad006500b267bce (patch) | |
tree | 564a3806f6c8c8a00162afa3e2ad8a7343ebb0e5 | |
parent | 4b3059977835d419e7c3b69e206ba817ce62d687 (diff) |
- Add missing goto in order to avoid a dereference of a null object
- While here remove lint comment
OK millert@
-rw-r--r-- | usr.sbin/authpf/authpf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/authpf/authpf.c b/usr.sbin/authpf/authpf.c index 44054a80b4b..7e5a1e3d6c3 100644 --- a/usr.sbin/authpf/authpf.c +++ b/usr.sbin/authpf/authpf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: authpf.c,v 1.124 2015/12/08 07:11:53 mmcc Exp $ */ +/* $OpenBSD: authpf.c,v 1.125 2016/03/29 14:53:27 mestre Exp $ */ /* * Copyright (C) 1998 - 2007 Bob Beck (beck@openbsd.org). @@ -342,7 +342,6 @@ main(int argc, char *argv[]) } } - /* NOTREACHED */ dogdeath: printf("\r\n\r\nSorry, this service is currently unavailable due to "); printf("technical difficulties\r\n\r\n"); @@ -756,6 +755,7 @@ change_filter(int add, const char *luser, const char *ipsrc) if((grent = getgrgid(getgid())) == NULL) { syslog(LOG_ERR, "Group not found user %s, gid %d", luser, getgid()); + goto error; } if (luser == NULL || !luser[0] || ipsrc == NULL || !ipsrc[0]) { |