3 ms·
And only works if you don't rely on any third-party libraries that take normal C strings. Which is to say, is unrealistic for many programs.
by compiler-guy 5y ago
And only works if you don't rely on any third-party libraries that take normal C strings.
Which is to say, is unrealistic for many programs.
- tgv 5y agoYou can use a library that also adds a trailing \O. I used it to interface C++.
- pjmlp 5y agoDepends on much they value security, even std::string has an extra null for c_str() calls.
- habibur 5y agoSend the pointer from the pair to 3rd party and not the pair itself. You lose the efficiency in 3rd party, but still retain your gain in your own code. Better than before.