So far i have the following code:
char* s;
s = new char[10];
__asm
{
mov ebx, s
mov byte ptr[ebx], 0x48 ;'H'
mov byte ptr[ebx + 1], 0x65 ;'e'
mov byte ptr[ebx + 2], 0x6C ;'l'
mov byte ptr[ebx + 3], 0x6C ;'l'
mov byte ptr[ebx + 4], 0x6F ;'o'
mov byte ptr[ebx + 5], 0x0A ; 'new line'
mov byte ptr[ebx + 6], 0;
mov eax, ebx
push eax
call DWORD ptr printf
pop ebx
}
I'd like to declare a char array in asm not using DB, how would that look like?