<p>You should try have a look in pdbt.c, query_udp():</p>

<pre><code>short int carrierid;
...
short int * idptr;
</code></pre>

<p>You should try have a look in pdb_server.c, udp_server():</p>

<pre><code>case PDB_VERSION_1:
...
                short int *_id
</code></pre>

<p>Try to change all the <em>short int</em> related to the carrier id to uint32_t (or <em>unsigned int</em>).<br>
For both of them, you should try to replace ntohs/htons with ntohl/htonl (see [1]).</p>

<p>[1] <a href="http://linux.die.net/man/3/ntohs">http://linux.die.net/man/3/ntohs</a></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/issues/433#issuecomment-163046622">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/AF36ZV1UBaKgMVoUCYnScdt5J4TJWopvks5pN1a3gaJpZM4Gw2Iw.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/issues/433#issuecomment-163046622"></link>
  <meta itemprop="name" content="View Issue"></meta>
</div>
<meta itemprop="description" content="View this Issue on GitHub"></meta>
</div>