Merge pull request #5714 from alexischr/update_bockbuild
[mono.git] / mono / sgen / sgen-hash-table.c
index 61c78e9bf56b703bc1c96edf51de6e0a827338df..3ceebc77f30c738e52d2086a73b70da368fcb215 100644 (file)
@@ -1,5 +1,5 @@
-/*
- * sgen-hash-table.c
+/**
+ * \file
  *
  * Permission is hereby granted, free of charge, to any person obtaining
  * a copy of this software and associated documentation files (the
@@ -53,7 +53,7 @@ rehash (SgenHashTable *hash_table)
                new_size = g_spaced_primes_closest (hash_table->num_entries);
        }
 
-       new_hash = sgen_alloc_internal_dynamic (new_size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type, TRUE);
+       new_hash = (SgenHashTableEntry **)sgen_alloc_internal_dynamic (new_size * sizeof (SgenHashTableEntry*), hash_table->table_mem_type, TRUE);
        for (i = 0; i < old_hash_size; ++i) {
                for (entry = old_hash [i]; entry; entry = next) {
                        hash = hash_table->hash_func (entry->key) % new_size;
@@ -132,7 +132,7 @@ sgen_hash_table_replace (SgenHashTable *hash_table, gpointer key, gpointer new_v
                return FALSE;
        }
 
-       entry = sgen_alloc_internal (hash_table->entry_mem_type);
+       entry = (SgenHashTableEntry *)sgen_alloc_internal (hash_table->entry_mem_type);
        entry->key = key;
        memcpy (entry->data, new_value, hash_table->data_size);