瀏覽代碼

Kamailio compatiblity: export parse_method function to modules.

The parser function was originally static and we are now exporting
it to other object files so that they can reuse the method parser.
Jan Janak 16 年之前
父節點
當前提交
d8cd450f97
共有 2 個文件被更改,包括 3 次插入1 次删除
  1. 1 1
      parser/parse_methods.c
  2. 2 0
      parser/parse_methods.h

+ 1 - 1
parser/parse_methods.c

@@ -49,7 +49,7 @@ static int token_char(char _c)
   * Parse a method pointed by _next, assign its enum bit to _method, and update
   * _next past the method. Returns 1 if parse succeeded and 0 otherwise.
   */
-static int parse_method(str* _next, unsigned int* _method) 
+int parse_method(str* _next, unsigned int* _method) 
  {
 	 if (!_next || !_method) {
 		 LOG(L_ERR, "parse_method: Invalid parameter value\n");

+ 2 - 0
parser/parse_methods.h

@@ -57,5 +57,7 @@ enum method {
  */
 int parse_methods(str* _body, unsigned int* _methods);
 
+int parse_method(str* _next, unsigned int* _method);
+
 
 #endif /* PARSE_METHODS_H */