Why this is failing ? I am trying to match a substring using regex in C++STL. What I am doing wrong here ?
GCC Version :: (Linaro GCC 4.8-2014.04) 4.8.3
#include<regex>
using namespace std;
int main()
{
regex e("auth");
smatch m;
string s="Connected to a:b:c:d completed auth id=3, str=3";
//string s="auth";
bool match = regex_search(s,e);
if( match == true )
printf("matched");
else
printf("no match");
}