Browse Source

"method" contact parameter should be "methods", fixed by Juha Heinanen.

Jan Janak 21 years ago
parent
commit
080f7419e1
2 changed files with 5 additions and 5 deletions
  1. 4 4
      parser/parse_param.c
  2. 1 1
      parser/parse_param.h

+ 4 - 4
parser/parse_param.c

@@ -74,9 +74,9 @@ 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;
+		if ((_p->name.len == 7) &&
+		    (!strncasecmp(_p->name.s + 1, "ethods", 5))) {
+			_p->type = P_METHODS;
 			_h->contact.method = _p;
 		}
 		break;
@@ -459,7 +459,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;

+ 1 - 1
parser/parse_param.h

@@ -46,7 +46,7 @@ typedef enum ptype {
 	P_OTHER = 0, /* Unknown parameter */
 	P_Q,         /* Contact: q parameter */
 	P_EXPIRES,   /* Contact: expires parameter */
-	P_METHOD,    /* Contact: method parameter */
+	P_METHODS,   /* Contact: method parameter */
 	P_TRANSPORT, /* URI: transport parameter */
 	P_LR,        /* URI: lr parameter */
 	P_R2,        /* URI: r2 parameter (ser specific) */