[SOLVED]Variables Error

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
melgmry0101b
Member
Member
Posts: 109
Joined: Wed Nov 10, 2010 10:49 am

[SOLVED]Variables Error

Post by melgmry0101b »

Hi everyone,
I have a memory issue.
I have two Variables.
The first one's name is "Achar" and i am using this code to load it :

Code: Select all

static char* Achar = "I am empty";
The second one's name is "mus" and i am using this code to load it :

Code: Select all

static char* mus = "I am empty too";
I am using the first one to load a bitmap that contains the "A" char and the second one to load the mouse cursor bitmap in it.

My problem is:
when i load the mouse bitmap , the Achar variable overwriting with the contents of the mus var contents.
I have a memory manager.
i use this code to load the contents of the bitmap in the var:

Code: Select all

Achar = (char*)(bitmapp -> pixeldata);
---------------------------------------------
Thank you in advance :D
---------------------------------------------
Last edited by melgmry0101b on Mon Apr 04, 2011 2:01 pm, edited 1 time in total.
melgmry0101b
Member
Member
Posts: 109
Joined: Wed Nov 10, 2010 10:49 am

Re: Variables Error

Post by melgmry0101b »

it points to the data of the Bitmap
User avatar
Solar
Member
Member
Posts: 7615
Joined: Thu Nov 16, 2006 12:01 pm
Location: Germany
Contact:

Re: Variables Error

Post by Solar »

Machete Debugging. In your case, you did cut away too much before posting, and it is impossible to reproduce your problem given the information you provided. Make us see your problem on our computers.
Every good solution is obvious once you've found it.
melgmry0101b
Member
Member
Posts: 109
Joined: Wed Nov 10, 2010 10:49 am

Re: Variables Error

Post by melgmry0101b »

I've repaired it
It was an initialization error in a place in my OS
Sorry for the inconvenience
Post Reply