|
-
May 30th, 2009, 11:52 PM
#9
Re: basic string scope in std namespace
I'm not familiar with cURL. However, there are two questions you need to ask:
1) Will this data ever need to be passed to a function expecting a (non-const) char*?
2) Is it possible to have a 0 byte prior to the end of the data? (I don't mean the character '0', I mean the NULL byte.)
If the answer to either of these is yes, you'll be better off with a std::vector<char>. Otherwise a std::string should be just fine.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|