Branch: Tag:

2003-11-17

2003-11-17 14:39:48 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added more paranoia before accepting dumped bytecode.

Rev: src/encode.c:1.200
Rev: src/opcodes.c:1.159
Rev: src/opcodes.h:1.37
Rev: src/version.h:1.345

2:   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: opcodes.c,v 1.158 2003/11/15 16:40:04 grubba Exp $ + || $Id: opcodes.c,v 1.159 2003/11/17 14:39:47 grubba Exp $   */      #include "global.h" - RCSID("$Id: opcodes.c,v 1.158 2003/11/15 16:40:04 grubba Exp $"); + RCSID("$Id: opcodes.c,v 1.159 2003/11/17 14:39:47 grubba Exp $");   #include "constants.h"   #include "interpret.h"   #include "opcodes.h"
292:   };      struct instr instrs[F_MAX_INSTR - F_OFFSET]; + #ifdef PIKE_USE_MACHINE_CODE + size_t instrs_checksum; + #endif /* PIKE_USE_MACHINE_CODE */      char *low_get_f_name(int n, struct program *p)   {
397:   #endif    }    + #ifdef PIKE_USE_MACHINE_CODE +  instrs_checksum = hash_mem(instrs, sizeof(instrs), sizeof(instrs)); + #endif /* PIKE_USE_MACHINE_CODE */ +    #ifdef PIKE_DEBUG    for(i=1; i<F_MAX_OPCODE-F_OFFSET;i++)    {