mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] : ir250_checker.diff
@ 2002-06-11  0:53 Jean Tourrilhes
  0 siblings, 0 replies; only message in thread
From: Jean Tourrilhes @ 2002-06-11  0:53 UTC (permalink / raw)
  To: Jeff Garzik, irda-users, Linux kernel mailing list

ir250_checker.diff :
------------------
	o [CORRECT] Fix two bugs found by the Stanford checker in IrCOMM




diff -u -p linux/net/irda/ircomm/ircomm_core.d0.c linux/net/irda/ircomm/ircomm_core.c
--- linux/net/irda/ircomm/ircomm_core.d0.c	Mon Jun 10 11:28:44 2002
+++ linux/net/irda/ircomm/ircomm_core.c	Mon Jun 10 11:30:01 2002
@@ -512,7 +512,7 @@ int ircomm_proc_read(char *buf, char **s
 
 	self = (struct ircomm_cb *) hashbin_get_first(ircomm);
 	while (self != NULL) {
-		ASSERT(self->magic == IRCOMM_MAGIC, return len;);
+		ASSERT(self->magic == IRCOMM_MAGIC, break;);
 
 		if(self->line < 0x10)
 			len += sprintf(buf+len, "ircomm%d", self->line);
diff -u -p linux/net/irda/ircomm/ircomm_tty.d0.c linux/net/irda/ircomm/ircomm_tty.c
--- linux/net/irda/ircomm/ircomm_tty.d0.c	Mon Jun 10 11:28:57 2002
+++ linux/net/irda/ircomm/ircomm_tty.c	Mon Jun 10 11:31:09 2002
@@ -523,6 +523,9 @@ static void ircomm_tty_close(struct tty_
 	if (!tty)
 		return;
 
+	ASSERT(self != NULL, return;);
+	ASSERT(self->magic == IRCOMM_TTY_MAGIC, return;);
+
 	save_flags(flags); 
 	cli();
 
@@ -533,9 +536,6 @@ static void ircomm_tty_close(struct tty_
 		IRDA_DEBUG(0, __FUNCTION__ "(), returning 1\n");
 		return;
 	}
-
-	ASSERT(self != NULL, return;);
-	ASSERT(self->magic == IRCOMM_TTY_MAGIC, return;);
 
 	if ((tty->count == 1) && (self->open_count != 1)) {
 		/*

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2002-06-11  1:08 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-06-11  0:53 [PATCH] : ir250_checker.diff Jean Tourrilhes

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

all inboxes | Powered by JetHome®