summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDavid Sommerseth <davids@redhat.com>2009-06-04 17:40:01 +0200
committerDavid Sommerseth <davids@redhat.com>2009-06-04 17:40:01 +0200
commit842f44f4efff348367ff9be5972def06d899b77b (patch)
tree2995d7147559ef87d193b62d548f63d65d5b7186 /src
parent2cf4f28f6fc671478003b31c03b93e070eee9942 (diff)
downloadpython-dmidecode-842f44f4efff348367ff9be5972def06d899b77b.tar.gz
python-dmidecode-842f44f4efff348367ff9be5972def06d899b77b.tar.xz
python-dmidecode-842f44f4efff348367ff9be5972def06d899b77b.zip
Fixed compiling issues after commit 2cf4f28f6fc671478003b31c03b93e070eee9942
Also cleaned up a little bit more, removed more unneeded stuff.
Diffstat (limited to 'src')
-rw-r--r--src/dmidecode.c4
-rw-r--r--src/dmidecodemodule.h6
-rw-r--r--src/dmihelper.h8
3 files changed, 3 insertions, 15 deletions
diff --git a/src/dmidecode.c b/src/dmidecode.c
index fbc151a..0f77e67 100644
--- a/src/dmidecode.c
+++ b/src/dmidecode.c
@@ -5003,10 +5003,8 @@ static void dmi_table(u8 *type, u32 base, u16 len, u16 num, u16 ver, const char
u8 *next;
struct dmi_header h;
- int display;
to_dmi_header(&h, data);
- display = (type == NULL || type[h.type]) // FIXME: Is this check correct?
/*
** If a short entry is found (less than 4 bytes), not only it
@@ -5037,7 +5035,7 @@ static void dmi_table(u8 *type, u32 base, u16 len, u16 num, u16 ver, const char
next += 2;
xmlNode *handle_n = NULL;
- if(display) {
+ if( type == NULL || type[h.type] ) { // FIXME: Is this check correct?
if(next - buf <= len) {
/* TODO: ...
* if(opt->flags & FLAG_DUMP) {
diff --git a/src/dmidecodemodule.h b/src/dmidecodemodule.h
index 7d085b2..47b22b6 100644
--- a/src/dmidecodemodule.h
+++ b/src/dmidecodemodule.h
@@ -23,14 +23,12 @@
xmlNode *dmidecode_get_version(options *);
-//extern void dmi_decode(struct dmi_header *h, u16 ver, PyObject* pydata);
extern void dmi_dump(xmlNode *node, struct dmi_header *h);
extern xmlNode *dmi_decode(xmlNode *parent_n, struct dmi_header * h, u16 ver);
extern int address_from_efi(size_t * address);
extern void to_dmi_header(struct dmi_header *h, u8 * data);
-// extern void dmi_table(u8 *type, const struct string_keyword *opt_string, u32 base, u16 len, u16 num, u16 ver, const char *devmem);
-extern int smbios_decode(u8 *type, const struct string_keyword *opt_string, u8 *buf, const char *devmem, xmlNode *node);
-extern int legacy_decode(u8 *type, const struct string_keyword *opt_string, u8 *buf, const char *devmem, xmlNode *node);
+extern int smbios_decode(u8 *type, u8 *buf, const char *devmem, xmlNode *node);
+extern int legacy_decode(u8 *type, u8 *buf, const char *devmem, xmlNode *node);
extern xmlNode *smbios_decode_get_version(u8 * buf, const char *devmem);
extern xmlNode *legacy_decode_get_version(u8 * buf, const char *devmem);
extern void *mem_chunk(size_t base, size_t len, const char *devmem);
diff --git a/src/dmihelper.h b/src/dmihelper.h
index ccf840d..b0816b7 100644
--- a/src/dmihelper.h
+++ b/src/dmihelper.h
@@ -78,14 +78,6 @@ typedef struct _dmi_minor {
struct _dmi_minor *next;
} dmi_minor;
-
-/*** dmiopt.h ***/
-struct string_keyword {
- const char *keyword;
- u8 type;
- u8 offset;
-};
-
/*** dmiopt.h ***/
typedef struct _options {
const char *devmem;