Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Estor

Visual Studio 6.0 C/C++ Bug ?

This topic is 5612 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello Let me introduse problem, this pice of code: char *var_a = "b"; int main () { char *var_b = "a"; var_a[0] = ''A''; var_b[0] = ''B''; return (0); } generates Acces Valiation when compiled with Visual 6.0 C/C++. When I compile it on Borland 5.1 C/C++ it works corect. Prabobly Visual C is puting this pointers in code memory (referenced by [CS] Descryptor). Is there any switch to force alocating data in data memory ? Maybe there is other reason why it is not workin corectly only when compiled with Visual C. "Never use brutal force, always HAMMER !!!"

Share this post


Link to post
Share on other sites
Advertisement
Guest Anonymous Poster
var_a is pointing to a constant string. Can''t modify it.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
That goes for var_b too, of course

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Except that I meant "string literal" instead of "constant string"

Share this post


Link to post
Share on other sites
estor i am compeled to note that your spelling is atrosious. how cvan you expect to become a good programer when your gramar skills are so obsenely limited?

Share this post


Link to post
Share on other sites
quote:
Original post by YodaTheCoda
estor i am compeled to note that your spelling is atrosious. how cvan you expect to become a good programer when your gramar skills are so obsenely limited?


Sorry... I understand what im reading, but I have problems with writeing. But all the time I''m learning. 8)

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
Yoda: Green little aliens backwards talkin does who, whine grammar shouldn''t about

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!