M
M
Moolzv Rivers2020-02-14 15:06:16
assembler
Moolzv Rivers, 2020-02-14 15:06:16

[MASM32] After calling my function, the program closes. What to do?

Hello.
There is this code:

...
addValues proc near
  add ebx, ecx
  ret
addValues endp

start: 
  invoke AllocConsole
  
        mov ebx, 10
       mov ecx, 10        

        call addValues

  invoke StdOut, firstMes
    
  invoke ExitProcess, 0
end start

After calling the addValues ​​function, the program closes and does not display the value. Why?

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question