Branch: Tag:

2004-03-11

2004-03-11 12:55:47 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Added some debug code that might trigger on OSF/1.

Rev: src/pike_types.c:1.232

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: pike_types.c,v 1.231 2004/03/10 18:08:12 grubba Exp $ + || $Id: pike_types.c,v 1.232 2004/03/11 12:55:47 grubba Exp $   */      #include "global.h" - RCSID("$Id: pike_types.c,v 1.231 2004/03/10 18:08:12 grubba Exp $"); + RCSID("$Id: pike_types.c,v 1.232 2004/03/11 12:55:47 grubba Exp $");   #include <ctype.h>   #include "svalue.h"   #include "pike_types.h"
330:    unsigned INT32 index = hash % pike_type_hash_size;    struct pike_type *t;    +  /* PIKE_DEBUG code */ +  if (index >= pike_type_hash_size) { +  Pike_fatal("Modulo operation failed for hash:%u, index:%u, size:%u.\n", +  hash, index, pike_type_hash_size); +  } +  /* End PIKE_DEBUG code */ +     for(t = pike_type_hash[index]; t; t = t->next) {    if ((t->hash == hash) && (t->type == type) &&    (t->car == car) && (t->cdr == cdr)) {