projects
/
bison.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Version 2.4.1b.
[bison.git]
/
src
/
muscle_tab.c
diff --git
a/src/muscle_tab.c
b/src/muscle_tab.c
index 43415716b1b4d40b31917850e08c1e40b88400b3..570add7056c12bd7d6d04d990070fc16f290f016 100644
(file)
--- a/
src/muscle_tab.c
+++ b/
src/muscle_tab.c
@@
-1,7
+1,6
@@
/* Muscle table manager for Bison.
/* Muscle table manager for Bison.
- Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2009 Free Software
- Foundation, Inc.
+ Copyright (C) 2001-2007, 2009-2010 Free Software Foundation, Inc.
This file is part of Bison, the GNU Compiler Compiler.
This file is part of Bison, the GNU Compiler Compiler.
@@
-121,7
+120,8
@@
muscle_insert (char const *key, char const *value)
/* First insertion in the hash. */
entry = xmalloc (sizeof *entry);
entry->key = key;
/* First insertion in the hash. */
entry = xmalloc (sizeof *entry);
entry->key = key;
- hash_insert (muscle_table, entry);
+ if (!hash_insert (muscle_table, entry))
+ xalloc_die ();
}
else
free (entry->storage);
}
else
free (entry->storage);
@@
-150,7
+150,8
@@
muscle_grow (const char *key, const char *val, const char *separator)
/* First insertion in the hash. */
entry = xmalloc (sizeof *entry);
entry->key = key;
/* First insertion in the hash. */
entry = xmalloc (sizeof *entry);
entry->key = key;
- hash_insert (muscle_table, entry);
+ if (!hash_insert (muscle_table, entry))
+ xalloc_die ();
entry->value = entry->storage = xstrdup (val);
}
else
entry->value = entry->storage = xstrdup (val);
}
else