There is no problem with the statement
s = "some info\n" + s;
So the problem is elsewhere in your code.
I know that the statement is correct, but when executing the program, it fails right there.
But the weirdest part is that it was working before, and it has stopped working.
What do you mean "fails right there"?
That means that the program stops running.
I'm working on Windows and with minGW for compilation.
Well first what did you change.