GetCL in the masm32 include file.
CODE
.586
.model flat,stdcall
option casemap:none
include \masm32\include\kernel32.inc
include \masm32\include\masm32.inc
includelib \masm32\lib\kernel32.lib
includelib \masm32\lib\masm32.lib
.DATA?
buffer1 db 512 dup (?)
buffer2 db 512 dup (?)
.CODE
start:
invoke GetCL,1,addr buffer1 ;get first argument
invoke GetCL,2,addr buffer2 ;get second argument
invoke ExitProcess,0
end start
as you can see the function is vulnerable to buffer overflows so you need to use extensive checking yourself...