patch-2.4.7 linux/net/irda/irlan/irlan_common.c
Next file: linux/net/irda/irlap.c
Previous file: linux/net/irda/irias_object.c
Back to the patch index
Back to the overall index
- Lines: 39
- Date:
Wed Jul 4 11:50:38 2001
- Orig file:
v2.4.6/linux/net/irda/irlan/irlan_common.c
- Orig date:
Sat Nov 11 18:11:23 2000
diff -u --recursive --new-file v2.4.6/linux/net/irda/irlan/irlan_common.c linux/net/irda/irlan/irlan_common.c
@@ -209,6 +209,7 @@
struct irlan_cb *self;
IRDA_DEBUG(2, __FUNCTION__ "()\n");
+ ASSERT(irlan != NULL, return NULL;);
/*
* Initialize the irlan structure.
@@ -224,8 +225,6 @@
*/
self->magic = IRLAN_MAGIC;
- ASSERT(irlan != NULL, return NULL;);
-
sprintf(self->dev.name, "%s", "unknown");
self->dev.priv = (void *) self;
@@ -1074,19 +1073,18 @@
{
struct irlan_cb *self;
unsigned long flags;
+ ASSERT(irlan != NULL, return 0;);
save_flags(flags);
cli();
- ASSERT(irlan != NULL, return 0;);
-
len = 0;
len += sprintf(buf+len, "IrLAN instances:\n");
self = (struct irlan_cb *) hashbin_get_first(irlan);
while (self != NULL) {
- ASSERT(self->magic == IRLAN_MAGIC, return len;);
+ ASSERT(self->magic == IRLAN_MAGIC, break;);
len += sprintf(buf+len, "ifname: %s,\n",
self->dev.name);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)