char * _first_switch_bit = (char *)first_switch_bit.c_str()

char * _first_switch_bit = (char *)first_switch_bit.c_str()


WHat does tis code do? convert c_str into std::string?
Last edited on
It is directly accessing underlying character array of std::string.
It is a really bad idea. Don't do this.
Last edited on
@MiiNiPaa

Thanks.Okay.Will try to make it a better code.Coz currently refer to senior's code.
Topic archived. No new replies allowed.