public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] 2.4.13pre3aa1: expand_fdset() may use invalid pointer
@ 2001-10-17 18:32 Chip Salzenberg
  2001-10-17 18:42 ` Andrea Arcangeli
  0 siblings, 1 reply; 6+ messages in thread
From: Chip Salzenberg @ 2001-10-17 18:32 UTC (permalink / raw)
  To: Andrea Arcangeli; +Cc: Linux Kernel

[-- Attachment #1: Type: text/plain, Size: 318 bytes --]

In 2.4.13pre3aa1, expand_fdset() in fs/file.c has a couple of
execution paths that call kfree() on a pointer that hasn't yet been
initialized.  A minimal patch is attached.
-- 
Chip Salzenberg               - a.k.a. -              <chip@pobox.com>
 "We have no fuel on board, plus or minus 8 kilograms."  -- NEAR tech

[-- Attachment #2: aa-files_struct_rcu-2.4.10-04-1-kfree-fix --]
[-- Type: text/plain, Size: 286 bytes --]


Index: linux/fs/file.c
--- linux/fs/file.c.old	Tue Oct 16 23:28:16 2001
+++ linux/fs/file.c	Wed Oct 17 00:29:43 2001
@@ -203,5 +203,5 @@
 	fd_set *new_openset = 0, *new_execset = 0;
 	int error, nfds = 0;
-	struct rcu_fd_set *arg;
+	struct rcu_fd_set *arg = NULL;
 
 	error = -EMFILE;

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2001-10-18 10:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2001-10-17 18:32 [PATCH] 2.4.13pre3aa1: expand_fdset() may use invalid pointer Chip Salzenberg
2001-10-17 18:42 ` Andrea Arcangeli
2001-10-18  6:41   ` Maneesh Soni
2001-10-18  8:22     ` Andrea Arcangeli
2001-10-18  9:48       ` Maneesh Soni
2001-10-18 10:06         ` Andrea Arcangeli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox