No - but your data and the pattern do not match.
You are searching for "zero or more 'a' followed by a newline character and the string '123'" which is not present in your sample data of "aaa"
Try calling it this way:
bool b = MatchWithGrep("(a)*", "aaa\\n123");
And it might work better...