<p>In <a href="https://github.com/kamailio/kamailio/pull/390#discussion_r44554482">modules/rtpengine/rtpengine_hash.c</a>:</p>
<pre style='color:#555'>> +    }
> +  LM_DBG("rtpengine_hash_table size = %d\n", hash_table_size);
> +
> +  // init hashtable
> +  rtpengine_hash_table = shm_malloc(sizeof(struct rtpengine_hash_table));
> +  if (!rtpengine_hash_table) {
> +          LM_ERR("no shm left to create rtpengine_hash_table\n");
> +          return 0;
> +  }
> +
> +  // init hashtable entry_list
> +  rtpengine_hash_table->entry_list = shm_malloc(hash_table_size * sizeof(struct rtpengine_hash_entry));
> +
> +  // init hashtable entry_list[i] (head never filled)
> +  for (i = 0; i < hash_table_size; i++) {
> +          rtpengine_hash_table->entry_list[i] = shm_malloc(sizeof(struct rtpengine_hash_entry));
</pre>
<p>I don't think shm_malloc() automatically zeroes the memory, and the lookup routines seem to do a strcmp on the head entries call-ID too, so the call-ID needs to be initialized as well.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br>Reply to this email directly or <a href="https://github.com/kamailio/kamailio/pull/390/files#r44554482">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AF36ZaD67QulXX1TkRfBw2Xr0gFEHIAkks5pE2hqgaJpZM4GcraR.gif" width="1" /></p>
<div itemscope itemtype="http://schema.org/EmailMessage">
<div itemprop="action" itemscope itemtype="http://schema.org/ViewAction">
  <link itemprop="url" href="https://github.com/kamailio/kamailio/pull/390/files#r44554482"></link>
  <meta itemprop="name" content="View Pull Request"></meta>
</div>
<meta itemprop="description" content="View this Pull Request on GitHub"></meta>
</div>