diff options
Diffstat (limited to 'catsprintf.h')
-rw-r--r-- | catsprintf.h | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/catsprintf.h b/catsprintf.h index 2c06130..46ac8e2 100644 --- a/catsprintf.h +++ b/catsprintf.h @@ -4,7 +4,24 @@ #include <stdarg.h> #include <string.h> #include <stdio.h> -int catsprintf(char *buf, int major, const char *format, ...); -/* sed -i -e 's/\<printf(/catsprintf(buffer, /g' dmidecode.c */ +#include <stdlib.h> +#include <assert.h> + +typedef struct _dmi_codes_major { + const unsigned short code; + const char *id; + const char *desc; +} dmi_codes_major; + +typedef struct _dmi_minor { + long id; + dmi_codes_major* major; + char *key; + char value[512]; + struct _dmi_minor* last; +} dmi_minor; + +int catsprintf(char *buf, const char *format, ...); +dmi_minor* dmiAppendObject(long code, char const *key, const char *format, ...); #endif |