Fix another Coverity problem by adding an assert that says that
Rafael Garcia-Suarez [Tue, 9 May 2006 13:18:34 +0000 (13:18 +0000)]
some string we got from the lexer is null-terminated

p4raw-id: //depot/perl@28137

op.c

diff --git a/op.c b/op.c
index a866fcb..30231d3 100644 (file)
--- a/op.c
+++ b/op.c
@@ -248,6 +248,7 @@ Perl_allocmy(pTHX_ char *name)
            /* 1999-02-27 mjd@plover.com */
            char *p;
            p = strchr(name, '\0');
+           assert(p);
            /* The next block assumes the buffer is at least 205 chars
               long.  At present, it's always at least 256 chars. */
            if (p - name > 200) {