For some reason excode is throwing this error when I try to cin into a string.
test(5640) malloc: * error for object 0x1000041c0: pointer being freed was not allocated * set a breakpoint in malloc_error_break to debug Program received signal: “SIGABRT”. sharedlibrary apply-load-rules all
Here is the code that produced that:
#include <iostream>
#include <string>
using namespace std;
int main()
{
string hello;
cout << "Enter a string";
cin >> hello;
return 0;
}
So does anybody have a solution?