Subversion Repositories Kolibri OS

Rev

Rev 802 | Rev 916 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 802 Rev 819
Line 3... Line 3...
3
;; Copyright (C) KolibriOS team 2004-2008. All rights reserved. ;;
3
;; Copyright (C) KolibriOS team 2004-2008. All rights reserved. ;;
4
;; Distributed under terms of the GNU General Public License    ;;
4
;; Distributed under terms of the GNU General Public License    ;;
5
;;                                                              ;;
5
;;                                                              ;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 7... Line 7...
7
 
7
 
Line 8... Line 8...
8
$Revision: 802 $
8
$Revision: 819 $
9
 
9
 
Line 386... Line 386...
386
endp
386
endp
Line 387... Line 387...
387
 
387
 
388
align 4
388
align 4
Line -... Line 389...
-
 
389
proc reg_service stdcall, name:dword, handler:dword
-
 
390
 
389
proc reg_service stdcall, name:dword, handler:dword
391
	   push ebx
Line 390... Line 392...
390
 
392
 
391
	   xor eax, eax
393
           xor eax, eax
Line 392... Line 394...
392
 
394
 
393
	   cmp [name], eax
395
	   cmp [name], eax
Line 394... Line -...
394
	   je .fail
-
 
395
 
396
	   je .fail
396
	   cmp [handler], eax
397
 
397
	   je .fail
-
 
398
 
398
	   cmp [handler], eax
399
	   push ebx
399
	   je .fail
Line 400... Line -...
400
	   mov eax, SRV_SIZE
-
 
401
	   call malloc		 ;call alloc_service
400
 
402
	   pop ebx
401
	   mov eax, SRV_SIZE
403
	   test eax, eax
402
	   call malloc		 ;call alloc_service
404
	   jz .fail
403
	   test eax, eax
405
 
404
	   jz .fail
Line 427... Line 426...
427
	   mov [eax+SRV.srv_proc], ecx
426
	   mov [eax+SRV.srv_proc], ecx
428
	   pop ebx
427
	   pop ebx
429
	   ret
428
	   ret
430
.fail:
429
.fail:
431
	   xor eax, eax
430
	   xor eax, eax
-
 
431
           pop ebx
432
	   ret
432
	   ret
433
endp
433
endp
Line 434... Line 434...
434
 
434
 
435
align 4
435
align 4