부산IT학원/스마트컨트롤러
20140826 (작성 중인 프로그램)
EHOzlO
2014. 8. 26. 17:24
127일차
---------------------
작성 중인 프로그램
---------------------
------- 현재 작성 중인 프로그램은 windows loader 같은 프로그램이다.
새로운 프로그램을 불러 올 때마다 heap을 할당 받고,
할당 받은 stack에 ESP를 위치하게 한다.
data 영역은 0x2000 만큼 떨어져 있다고 한다.
그래서 우리가 받은 자료 t1.exe를 link 한 프로그램으로 돌리면 뻑이 났다.
link /subsystem:console /entry:init /nodefaultlib /out:t1.exe /base:0x520000 init.obj monitor.obj t1.obj
이래 고치면 뻑이 안난다.
->link /subsystem:console /entry:init /nodefaultlib /out:t1.exe /base:0x430000 init.obj monitor.obj t1.obj
추가한 함수