Explorar el Código

nathelper(k): print bad contact uri

- help in troubleshooting bad sip clients
Daniel-Constantin Mierla hace 15 años
padre
commit
a93f7ad1ce
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      modules_k/nathelper/nhelpr_funcs.c

+ 2 - 1
modules_k/nathelper/nhelpr_funcs.c

@@ -406,7 +406,8 @@ get_contact_uri(struct sip_msg* _m, struct sip_uri *uri, contact_t** _c)
                 return -1;
 
         if (parse_uri((*_c)->uri.s, (*_c)->uri.len, uri) < 0 || uri->host.len <= 0) {
-                LM_ERR("failed to parse Contact URI\n");
+                LM_ERR("failed to parse Contact URI [%.*s]\n",
+                        (*_c)->uri.len, ((*_c)->uri.s)?(*_c)->uri.s:"");
                 return -1;
         }
         return 0;