Skip to content
Snippets Groups Projects
Commit 5106ee4a authored by Markus Amsler's avatar Markus Amsler Committed by Alexandre Julliard
Browse files

Initialize .COM stack.

parent 63289cd6
No related branches found
No related tags found
No related merge requests found
......@@ -315,6 +315,11 @@ static BOOL MZ_DoLoadImage( HANDLE hFile, LPCSTR filename, OverlayBlock *oblk )
init_ip = mz_header.e_ip;
init_ss = load_seg+mz_header.e_ss;
init_sp = mz_header.e_sp;
if (old_com){
/* .COM files exit with ret. Make sure they jump to psp start (=int 20) */
WORD* stack = PTR_REAL_TO_LIN(init_ss, init_sp);
*stack = 0;
}
TRACE("entry point: %04x:%04x\n",init_cs,init_ip);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment