opensips/modules/enum/enum_mod.c

changeset 18
8ec65b8f6e2c
parent 12
a3ac912f2857
equal deleted inserted replaced
0:61200337f51b 1:074233a9a125
53 53
54 char* branchlabel = "i"; 54 char* branchlabel = "i";
55 char* i_enum_suffix = "e164.arpa."; 55 char* i_enum_suffix = "e164.arpa.";
56 char* bl_algorithm = "cc"; 56 char* bl_algorithm = "cc";
57 57
58 char* isn_suffix = "freenum.org.";
59
58 60
59 /* 61 /*
60 * Internal module variables 62 * Internal module variables
61 */ 63 */
62 str suffix; 64 str suffix;
64 str service; 66 str service;
65 67
66 str i_suffix; 68 str i_suffix;
67 str i_branchlabel; 69 str i_branchlabel;
68 str i_bl_alg; 70 str i_bl_alg;
71
72 str isnsuffix;
69 73
70 74
71 /* 75 /*
72 * Exported functions 76 * Exported functions
73 */ 77 */
92 {"i_enum_query", (cmd_function)i_enum_query_0, 0, 0, 0, REQUEST_ROUTE}, 96 {"i_enum_query", (cmd_function)i_enum_query_0, 0, 0, 0, REQUEST_ROUTE},
93 {"i_enum_query", (cmd_function)i_enum_query_1, 1, fixup_str_null, 0, 97 {"i_enum_query", (cmd_function)i_enum_query_1, 1, fixup_str_null, 0,
94 REQUEST_ROUTE}, 98 REQUEST_ROUTE},
95 {"i_enum_query", (cmd_function)i_enum_query_2, 2, fixup_str_str, 0, 99 {"i_enum_query", (cmd_function)i_enum_query_2, 2, fixup_str_str, 0,
96 REQUEST_ROUTE}, 100 REQUEST_ROUTE},
101 {"isn_query", (cmd_function)isn_query_0, 0, 0, 0, REQUEST_ROUTE},
102 {"isn_query", (cmd_function)isn_query_1, 1, fixup_str_null,
103 fixup_free_str_null, REQUEST_ROUTE},
104 {"isn_query", (cmd_function)isn_query_2, 2, fixup_str_str,
105 fixup_free_str_str, REQUEST_ROUTE},
97 {0, 0, 0, 0, 0, 0} 106 {0, 0, 0, 0, 0, 0}
98 }; 107 };
99 108
100 109
101 /* 110 /*
105 {"domain_suffix", STR_PARAM, &domain_suffix}, 114 {"domain_suffix", STR_PARAM, &domain_suffix},
106 {"tel_uri_params", STR_PARAM, &tel_uri_params}, 115 {"tel_uri_params", STR_PARAM, &tel_uri_params},
107 {"branchlabel", STR_PARAM, &branchlabel}, 116 {"branchlabel", STR_PARAM, &branchlabel},
108 {"i_enum_suffix", STR_PARAM, &i_enum_suffix}, 117 {"i_enum_suffix", STR_PARAM, &i_enum_suffix},
109 {"bl_algorithm", STR_PARAM, &bl_algorithm}, 118 {"bl_algorithm", STR_PARAM, &bl_algorithm},
119 {"isn_suffix", STR_PARAM, &isn_suffix},
110 {0, 0, 0} 120 {0, 0, 0}
111 }; 121 };
112 122
113 123
114 /* 124 /*
150 i_branchlabel.len = strlen(branchlabel); 160 i_branchlabel.len = strlen(branchlabel);
151 161
152 i_bl_alg.s = bl_algorithm; 162 i_bl_alg.s = bl_algorithm;
153 i_bl_alg.len = strlen(bl_algorithm); 163 i_bl_alg.len = strlen(bl_algorithm);
154 164
165 isnsuffix.s = isn_suffix;
166 isnsuffix.len = strlen(isnsuffix.s);
167
155 return 0; 168 return 0;
156 } 169 }
157 170

mercurial