We mostly use classical C strings, but the memory management around them
can get confusing and error prone. Let's use std::string for the cases
where we need to return a newly allocated string.
The generally recommended way is to include it from source files, not
headers. We had a mix of both. Let's try to be consistent and follow the
recommended way.
RegConfig.cxx:64: warning: cannot pass objects of non-POD type `struct
rfb::CStr' through `...'; call will abort at runtime
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3361 3789f03b-4d11-0410-bbf8-ca57d06f2519
CharArray somevariable = "somestring"
...are not allowed. It seems like MSVC does not correctly check
accessibility for temporaries. Chapter 12.2 of ISO/IEC 14882:2003(E):
> Even when the creation of the temporary object is avoided (12.8),
> all the semantic restrictions must be respected as if the temporary
> object was created. [Example: even if the copy constructor is not
> called, all the semantic restrictions, such as accessibility
> (clause 11), shall be satisfied. ]
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3344 3789f03b-4d11-0410-bbf8-ca57d06f2519