Hi!
Using VC++ 6.0, if I insert this piece of code into my program, I get the
"Unhandled exception. Acces violation" error:
--------------//------------------
char *file,*name;
name = attr.getNodeValue().transcode(); //It's a value from parsing an XML doc
strcpy(file,name);
-------------//-------------------
I know that I am problably accessing memory I don't own, or I did
not allocate enough memory. But my question is:
+ How can I solve this?
+ How can access the memory I own?
+ How can allocate memory? Wich are the commands?
TIA.
Using VC++ 6.0, if I insert this piece of code into my program, I get the
"Unhandled exception. Acces violation" error:
--------------//------------------
char *file,*name;
name = attr.getNodeValue().transcode(); //It's a value from parsing an XML doc
strcpy(file,name);
-------------//-------------------
I know that I am problably accessing memory I don't own, or I did
not allocate enough memory. But my question is:
+ How can I solve this?
+ How can access the memory I own?
+ How can allocate memory? Wich are the commands?
TIA.