Commit | Line | Data |
---|---|---|
980d1ab2 IJ |
1 | #ifndef HEXDEBUG_H |
2 | #define HEXDEBUG_H | |
3 | ||
4 | #include <stdio.h> | |
5 | #include <sys/types.h> | |
6 | ||
7 | static inline void hexdebug(FILE *file, const void *buffer, size_t len) | |
8 | { | |
9 | const uint8_t *array=buffer; | |
10 | size_t i; | |
11 | for (i=0; i<len; i++) | |
12 | fprintf(file,"%02x",array[i]); | |
13 | } | |
14 | ||
15 | #endif /*HEXDEBUG_H*/ |