flat assembler
Message board for the users of flat assembler.

Index > Windows > Ask a question

Author
Thread Post new topic Reply to topic
xyblack



Joined: 20 Mar 2008
Posts: 19
xyblack 05 Apr 2008, 07:54
Hi,Dear friends..

Ask a question,I have just learning "fasm"。Before use "MASM"。MASM Provided in the "RtlZeroMemory" function。 fasm Whether have similar Macro。I write a

mov edi,@stWndClass
mov ecx, sizeof.WNDCLASSEX
xor eax,eax
rep stosd

However, lack of access to local Variables address。

Is there a similar MACRO?
Post 05 Apr 2008, 07:54
View user's profile Send private message Reply with quote
vid
Verbosity in development


Joined: 05 Sep 2003
Posts: 7105
Location: Slovakia
vid 05 Apr 2008, 08:15
bug. you must "mov ecx, sizeof.WNDCLASSEX/4".

Local variables are addresses relative to EBP (eg. "mov eax, [ebp + 8]"), best way to get their address is to use LEA instruction:

Code:
lea edi, [local_variable]
    
Post 05 Apr 2008, 08:15
View user's profile Send private message Visit poster's website AIM Address MSN Messenger ICQ Number Reply with quote
xyblack



Joined: 20 Mar 2008
Posts: 19
xyblack 05 Apr 2008, 09:34
oh,yeah....

Thank You
Post 05 Apr 2008, 09:34
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.