OSDN Git Service

* objc/objc-act.c (hash_init): Use xcalloc.
authorshebs <shebs@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 22 Jun 2001 02:38:22 +0000 (02:38 +0000)
committershebs <shebs@138bc75d-0d04-0410-961f-82ee72b054a4>
Fri, 22 Jun 2001 02:38:22 +0000 (02:38 +0000)
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@43498 138bc75d-0d04-0410-961f-82ee72b054a4

gcc/ChangeLog
gcc/objc/objc-act.c

index 45495d6..57da611 100644 (file)
@@ -1,3 +1,7 @@
+2001-06-21  Stan Shebs  <shebs@apple.com>
+
+       * objc/objc-act.c (hash_init): Use xcalloc.
+
 2001-06-21  Richard Henderson  <rth@redhat.com>
 
        * flow.c (entry_exit_blocks): Initialize frequency.
index 076637e..af9a8bb 100644 (file)
@@ -5447,11 +5447,8 @@ build_ivar_reference (id)
 static void
 hash_init ()
 {
-  nst_method_hash_list = (hash *) xmalloc (SIZEHASHTABLE * sizeof (hash));
-  cls_method_hash_list = (hash *) xmalloc (SIZEHASHTABLE * sizeof (hash));
-
-  memset (nst_method_hash_list, 0, SIZEHASHTABLE * sizeof (hash));
-  memset (cls_method_hash_list, 0, SIZEHASHTABLE * sizeof (hash));
+  nst_method_hash_list = (hash *) xcalloc (SIZEHASHTABLE, sizeof (hash));
+  cls_method_hash_list = (hash *) xcalloc (SIZEHASHTABLE, sizeof (hash));
 }
 
 /* WARNING!!!!  hash_enter is called with a method, and will peek