Merge commit 'origin/ser_core_cvs'
[sip-router] / parser / parse_param.c
index c5ed012..5f204bb 100644 (file)
@@ -105,7 +105,7 @@ static inline void parse_event_dialog_class(param_hooks_t* h, param_t* p)
 
 /*
  * Try to find out parameter name, recognized parameters
- * are q, expires and method
+ * are q, expires and methods
  */
 static inline void parse_contact_class(param_hooks_t* _h, param_t* _p)
 {
@@ -138,10 +138,10 @@ static inline void parse_contact_class(param_hooks_t* _h, param_t* _p)
                
        case 'm':
        case 'M':
-               if ((_p->name.len == 6) &&
-                   (!strncasecmp(_p->name.s + 1, "ethod", 5))) {
-                       _p->type = P_METHOD;
-                       _h->contact.method = _p;
+               if ((_p->name.len == 7) &&
+                   (!strncasecmp(_p->name.s + 1, "ethods", 6))) {
+                       _p->type = P_METHODS;
+                       _h->contact.methods = _p;
                }
                break;
                
@@ -595,7 +595,7 @@ static inline void print_param(FILE* _o, param_t* _p)
        case P_OTHER:     type = "P_OTHER";     break;
        case P_Q:         type = "P_Q";         break;
        case P_EXPIRES:   type = "P_EXPIRES";   break;
-       case P_METHOD:    type = "P_METHOD";    break;
+       case P_METHODS:   type = "P_METHODS";   break;
        case P_TRANSPORT: type = "P_TRANSPORT"; break;
        case P_LR:        type = "P_LR";        break;
        case P_R2:        type = "P_R2";        break;