Graph::dag_string() returns string by value

In this case we called c_str() on the std::string returned by
Graph::dag_string() and tried to use the char * after the string it was
pointing to was out of scope. It resulted in undefined behavior. The fix
is to simply store the returned string and then call c_str() on the
stored string.
Merge branch 'develop' of github.com:XIA-Project/xia-core into develop
Merge branch 'develop' of github.com:XIA-Project/xia-core into develop