All of lore.kernel.org
 help / color / mirror / Atom feed
* [KJ] [PATCH] [trivial] drivers/isdn/hardware/eicon/message.c:
@ 2007-06-08 18:18 Andi Drebes
  0 siblings, 0 replies; only message in thread
From: Andi Drebes @ 2007-06-08 18:18 UTC (permalink / raw)
  To: kernel-janitors

This patch replaces an array size calculation in
drivers/isdn/hardware/eicon/message.c that was done using
sizeof with the ARRAY_SIZE macro.

Tested by compilation on an i386 box using "allyesconfig".
Diffed against Linus' git-tree.

Signed-off-by: Andi Drebes <lists-receive@programmierforen.de>
---
diff --git a/drivers/isdn/hardware/eicon/message.c b/drivers/isdn/hardware/eicon/message.c
index ccd35d0..582af66 100644
--- a/drivers/isdn/hardware/eicon/message.c
+++ b/drivers/isdn/hardware/eicon/message.c
@@ -552,7 +552,7 @@ word api_put(APPL   * appl, CAPI_MSG   * msg)
 
   for(j=0;j<MAX_MSG_PARMS+1;j++) msg_parms[j].length = 0;
   for(i=0, ret = _BAD_MSG;
-      i<(sizeof(ftable)/sizeof(struct _ftable));
+      i<ARRAY_SIZE(ftable);
       i++) {
 
     if(ftable[i].command=msg->header.command) {
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/kernel-janitors

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

only message in thread, other threads:[~2007-06-08 18:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-06-08 18:18 [KJ] [PATCH] [trivial] drivers/isdn/hardware/eicon/message.c: Andi Drebes

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.