![]() | ||||||||||
Messages in this thread Patch in this message |
Hi all, error path in sys_swapon() can pass negative error code to filp_close() which generates an oops, oneliner patch attached. Best regards. -- Andrey Panin | Embedded systems software engineer pazke@orbita1.ru | PGP key: wwwkeys.eu.pgp.netdiff -urN -X /usr/dontdiff /linux.vanilla/mm/swapfile.c /linux/mm/swapfile.c --- /linux.vanilla/mm/swapfile.c Wed Jan 30 01:07:49 2002 +++ /linux/mm/swapfile.c Tue Jan 29 21:23:46 2002 @@ -1073,7 +1073,7 @@ swap_list_unlock(); if (swap_map) vfree(swap_map); - if (swap_file) + if (swap_file && !IS_ERR(swap_file)) filp_close(swap_file, NULL); out: if (swap_header)[unhandled content-type:application/pgp-signature] | |||||||||
| Last update: 2005-03-22 11:15 [W:0.140 / U:0.260 seconds] ©2003-2008 Jasper Spaans | ||||||||||