aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Robinson <andr345@gmail.com>2009-05-20 17:57:54 +0200
committerAndreas Robinson <andr345@gmail.com>2009-05-21 12:31:21 +0200
commit5c7417c53f664375014809a1024c09e575789c61 (patch)
treeb9b84b9786584fa1b973fa7338947832e2ea198d
parenta5e4ae7aff7630572332f480f0175c2d0c15d1d4 (diff)
downloadmodule-init-tools-5c7417c53f664375014809a1024c09e575789c61.tar.gz
elfops: clear struct module_tables with memset()
Signed-off-by: Andreas Robinson <andr345@gmail.com>
-rw-r--r--elfops_core.c10
1 files changed, 1 insertions, 9 deletions
diff --git a/elfops_core.c b/elfops_core.c
index 051e7f7..4283d65 100644
--- a/elfops_core.c
+++ b/elfops_core.c
@@ -240,15 +240,7 @@ static void PERBIT(fetch_tables)(struct elf_file *module,
if (!strings || !syms)
return;
- tables->pci_table = NULL;
- tables->usb_table = NULL;
- tables->ccw_table = NULL;
- tables->ieee1394_table = NULL;
- tables->pnp_table = NULL;
- tables->pnp_card_table = NULL;
- tables->input_table = NULL;
- tables->serio_table = NULL;
- tables->of_table = NULL;
+ memset(tables, 0x00, sizeof(struct module_tables));
for (i = 0; i < size / sizeof(syms[0]); i++) {
char *name = strings + END(syms[i].st_name, conv);