From ac776f502efc23592e2e47bac31bda21f73af920 Mon Sep 17 00:00:00 2001 From: hidnplayr Date: Mon, 27 Aug 2012 20:12:11 +0000 Subject: [PATCH] When a process ends by function -1, kill all it's sockets. git-svn-id: svn://kolibrios.org@2941 a494cfbc-eb01-0410-851d-a64ba20cac60 --- kernel/branches/net/kernel.asm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/kernel/branches/net/kernel.asm b/kernel/branches/net/kernel.asm index bc65946dec..4240a70fb3 100644 --- a/kernel/branches/net/kernel.asm +++ b/kernel/branches/net/kernel.asm @@ -77,7 +77,7 @@ $Revision $ USE_COM_IRQ equ 1 ; make irq 3 and irq 4 available for PCI devices ; Enabling the next line will enable serial output console -debug_com_base equ 0x2f8 ; 0x3f8 is com1, 0x2f8 is com2, 0x3e8 is com3, 0x2e8 is com4, no irq's are used +;debug_com_base equ 0x2f8 ; 0x3f8 is com1, 0x2f8 is com2, 0x3e8 is com3, 0x2e8 is com4, no irq's are used include "proc32.inc" include "kglobals.inc" @@ -1928,6 +1928,13 @@ sys_end: call restore_default_cursor_before_killing popa @@: +;-------------------------------------- +; kill all sockets this process owns + pusha + mov edx, [TASK_BASE] + mov edx, [edx+TASKDATA.pid] + call SOCKET_process_end + popa ;-------------------------------------- mov ecx, [current_slot] mov eax, [ecx+APPDATA.tls_base]