Browse code

Teach the parser recognize PRACK and UPDATE methods

Signed-off-by: Jan Janak <jan@iptel.org>

Ovidiu Sas authored on 23/03/2009 19:09:40 • Jan Janak committed on 23/03/2009 19:09:40
Showing 3 changed files
... ...
@@ -79,7 +79,7 @@
79 79
 enum request_method { METHOD_UNDEF=0, METHOD_INVITE=1, METHOD_CANCEL=2, METHOD_ACK=4,
80 80
 	METHOD_BYE=8, METHOD_INFO=16, METHOD_REGISTER=32, METHOD_SUBSCRIBE=64,
81 81
 	METHOD_NOTIFY=128, METHOD_MESSAGE=256, METHOD_OPTIONS=512,
82
-	METHOD_OTHER=1024 };
82
+	METHOD_PRACK=1024, METHOD_UPDATE=2048, METHOD_OTHER=4096 };
83 83
 
84 84
 #define FL_FORCE_RPORT  (1 << 0)  /* force rport */
85 85
 #define FL_FORCE_ACTIVE (1 << 1)  /* force active SDP */
... ...
@@ -125,6 +125,8 @@ char* parse_first_line(char* buffer, unsigned int len, struct msg_start * fl)
125 125
 	else IFISMETHOD( NOTIFY, 'N')
126 126
 	else IFISMETHOD( MESSAGE, 'M')
127 127
 	else IFISMETHOD( OPTIONS, 'O')
128
+	else IFISMETHOD( PRACK, 'P')
129
+	else IFISMETHOD( UPDATE, 'U')
128 130
 	/* if you want to add another method XXX, include METHOD_XXX in
129 131
            H-file (this is the value which you will take later in
130 132
            processing and define XXX_LEN as length of method name;
... ...
@@ -60,6 +60,8 @@
60 60
 #define NOTIFY_LEN 6
61 61
 #define MESSAGE_LEN 7
62 62
 #define OPTIONS_LEN 7
63
+#define PRACK_LEN 5
64
+#define UPDATE_LEN 6
63 65
 
64 66
 struct msg_start {
65 67
 	int type;					/* Type of the Message - Request/Response */