@@ -46,6 +46,7 @@ http_endpoint::http_endpoint(const string& url, bool family, bool registration):
4646 bool first = true ;
4747 if (registration)
4848 {
49+ this ->url_modded = " ^/" ;
4950 for (unsigned int i = 0 ; i< parts.size (); i++)
5051 {
5152 if ((parts[i] != " " ) && (parts[i][0 ] != ' {' ))
@@ -107,7 +108,8 @@ http_endpoint::http_endpoint(const string& url, bool family, bool registration):
107108 }
108109 this ->url_pieces .push_back (parts[i]);
109110 }
110- regcomp (&(this ->re_url_modded ), url_modded.c_str (), REG_EXTENDED|REG_ICASE);
111+ this ->url_modded += " $" ;
112+ regcomp (&(this ->re_url_modded ), url_modded.c_str (), REG_EXTENDED|REG_ICASE|REG_NOSUB);
111113 reg_compiled = true ;
112114 }
113115 else
@@ -138,7 +140,7 @@ http_endpoint::http_endpoint(const http_endpoint& h):
138140 reg_compiled (h.reg_compiled)
139141{
140142 if (this ->reg_compiled )
141- regcomp (&(this ->re_url_modded ), url_modded.c_str (), REG_EXTENDED|REG_ICASE);
143+ regcomp (&(this ->re_url_modded ), url_modded.c_str (), REG_EXTENDED|REG_ICASE|REG_NOSUB );
142144}
143145
144146http_endpoint& http_endpoint::operator =(const http_endpoint& h)
@@ -148,7 +150,7 @@ http_endpoint& http_endpoint::operator =(const http_endpoint& h)
148150 this ->family_url = h.family_url ;
149151 this ->reg_compiled = h.reg_compiled ;
150152 if (this ->reg_compiled )
151- regcomp (&(this ->re_url_modded ), url_modded.c_str (), REG_EXTENDED|REG_ICASE);
153+ regcomp (&(this ->re_url_modded ), url_modded.c_str (), REG_EXTENDED|REG_ICASE|REG_NOSUB );
152154 this ->url_pars = h.url_pars ;
153155 this ->url_pieces = h.url_pieces ;
154156 this ->chunk_positions = h.chunk_positions ;
0 commit comments