forked from KolibriOS/kolibrios
Kernel: Deleted support MENUET00 header of executable files;
Updated process_information structure. git-svn-id: svn://kolibrios.org@10008 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
31193af81e
commit
6345e58caa
@ -499,6 +499,8 @@ struct process_information
|
||||
dw ? ; +52
|
||||
client_box BOX ; +54
|
||||
wnd_state db ? ; +70
|
||||
event_mask dd ? ; +71
|
||||
keyboard_mode db ? ; +75
|
||||
ends
|
||||
|
||||
struct APPDATA
|
||||
@ -573,7 +575,7 @@ TSTATE_TERMINATING = 4
|
||||
TSTATE_WAITING = 5
|
||||
TSTATE_FREE = 9
|
||||
|
||||
; Window constants:
|
||||
; Window constants(fl_wstate):
|
||||
WSTATE_NORMAL = 00000000b
|
||||
WSTATE_MAXIMIZED = 00000001b
|
||||
WSTATE_MINIMIZED = 00000010b
|
||||
@ -612,12 +614,13 @@ struct WDATA
|
||||
rb 3
|
||||
saved_box BOX
|
||||
cursor dd ?
|
||||
temp_cursor dd ?
|
||||
temp_cursor dd ? ;?
|
||||
draw_bgr_x dd ?
|
||||
draw_bgr_y dd ?
|
||||
draw_data RECT
|
||||
thread dd ? ; ptr APPDATA
|
||||
rb 12
|
||||
buttons rd 1 ; ptr array buttons
|
||||
rb 12 - 4
|
||||
ends
|
||||
|
||||
label WDATA.fl_wstyle byte at WDATA.cl_workarea + 3
|
||||
|
@ -10,15 +10,6 @@ $Revision$
|
||||
|
||||
GREEDY_KERNEL = 0
|
||||
|
||||
struct APP_HEADER_00_
|
||||
banner dq ?
|
||||
version dd ? ;+8
|
||||
start dd ? ;+12
|
||||
i_end dd ? ;+16
|
||||
mem_size dd ? ;+20
|
||||
i_param dd ? ;+24
|
||||
ends
|
||||
|
||||
struct APP_HEADER_01_
|
||||
banner dq ?
|
||||
version dd ? ;+8
|
||||
@ -215,9 +206,6 @@ endp
|
||||
|
||||
align 4
|
||||
test_app_header:
|
||||
virtual at eax
|
||||
APP_HEADER_00 APP_HEADER_00_
|
||||
end virtual
|
||||
virtual at eax
|
||||
APP_HEADER_01 APP_HEADER_01_
|
||||
end virtual
|
||||
@ -227,36 +215,6 @@ test_app_header:
|
||||
cmp word [eax+4], 'ET'
|
||||
jne .fail
|
||||
|
||||
cmp [eax+6], word '00'
|
||||
jne .check_01_header
|
||||
|
||||
mov ecx, [APP_HEADER_00.start]
|
||||
mov [ebx + APP_HDR.eip], ecx
|
||||
mov edx, [APP_HEADER_00.mem_size]
|
||||
mov [ebx + APP_HDR._emem], edx
|
||||
|
||||
cmp edx, [APP_HEADER_00.i_end]
|
||||
jb .fail
|
||||
|
||||
cmp edx, OS_BASE ;check memory
|
||||
jae .fail
|
||||
mov ecx, [pg_data.pages_free]
|
||||
shl ecx, 12 ; ecx * 4kb
|
||||
cmp edx, ecx
|
||||
jae .fail
|
||||
|
||||
shr edx, 1
|
||||
sub edx, 0x10
|
||||
mov [ebx + APP_HDR.esp], edx
|
||||
mov ecx, [APP_HEADER_00.i_param]
|
||||
mov [ebx + APP_HDR.cmdline], ecx
|
||||
mov [ebx + APP_HDR.path], 0
|
||||
mov edx, [APP_HEADER_00.i_end]
|
||||
mov [ebx + APP_HDR._edata], edx
|
||||
ret
|
||||
|
||||
.check_01_header:
|
||||
|
||||
cmp [eax+6], word '01'
|
||||
je @f
|
||||
cmp [eax+6], word '02'
|
||||
@ -847,11 +805,7 @@ common_app_entry:
|
||||
and edi, -PAGE_SIZE
|
||||
sub edi, ecx
|
||||
dec edi
|
||||
cmp word [6], '00'
|
||||
jne @f
|
||||
mov [APP_HEADER_00_.i_param], edi
|
||||
jmp .copy_cmdline
|
||||
@@:
|
||||
|
||||
mov [APP_HEADER_01_.i_param], edi
|
||||
.copy_cmdline:
|
||||
inc ecx ; keep in mind about 0 in the end
|
||||
|
Loading…
Reference in New Issue
Block a user