add an abort for a case that can't happen

This commit is contained in:
christos 2019-10-05 20:22:36 +00:00
parent 86bd1b8280
commit 3379dd2438
1 changed files with 4 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: main.c,v 1.34 2015/03/12 12:40:41 christos Exp $ */
/* $NetBSD: main.c,v 1.35 2019/10/05 20:22:36 christos Exp $ */
/*-
* Copyright (c) 2013 Johann 'Myrkraverk' Oskarsson.
@ -39,7 +39,7 @@
#endif
#include <sys/cdefs.h>
__RCSID("$NetBSD: main.c,v 1.34 2015/03/12 12:40:41 christos Exp $");
__RCSID("$NetBSD: main.c,v 1.35 2019/10/05 20:22:36 christos Exp $");
#ifdef __FBSDID
__FBSDID("$FreeBSD: head/usr.bin/sed/main.c 252231 2013-06-26 04:14:19Z pfg $");
#endif
@ -268,6 +268,8 @@ again:
s = script->s;
state = ST_STRING;
goto again;
default:
abort();
}
case ST_FILE:
if ((p = fgets(buf, n, f)) != NULL) {