@@ -167,6 +167,12 @@ static inline int authenticate(struct sip_msg* msg, str* realm,
received = NULL;
switch(auth_api.pre_auth(msg, realm, hftype, &h, NULL)) {
+ default:
+ BUG("unexpected reply '%d'.\n", auth_api.pre_auth(msg, realm, hftype,
+ &h, NULL));
+#ifdef EXTRA_DEBUG
+ abort();
+#endif
case ERROR:
case BAD_CREDENTIALS:
ret = -3;
@@ -60,7 +60,7 @@ int sd_lookup(struct sip_msg* _msg, char* _index, char* _str2)
db_rec_t* rec;
/* init */
- i = (int)_index;
+ i = (int)(long)_index;
/* Retrieve the owner of the record */
if (get_from_uid(&uid, _msg) < 0) {
@@ -223,7 +223,7 @@ static int sd_lookup_fixup(void** param, int param_no)
}
ptr[tables_no].table = (char*)*param;
ptr[tables_no].lookup_num = NULL;
- *param = (void*)tables_no;
+ *param = (void*)(long)tables_no;
tables_no++;
tables = ptr;