title: Initializing std::string with const char * results in gibberish
body: <p>I use rapidjson to read JSON files, and some of the values are string. Now, rapidjson's <code>GetString()</code> method returns a <code>const char *</code>. I'd like to store this in <code>std::string</code>, though. I've tried this:</p>
  
  <pre><code>const char* foo = d["foo"].GetString();
  printf("Foo: %s\n", foo); // Prints correctly
  
  std::string fooStr(foo);
  printf("FooString: %s\n", fooStr); // Gibberish
  </code></pre>
  
  <p>How do I get the correct <code>std::string</code>?</p>