Index: altium/pcbdoc_bin.c =================================================================== --- altium/pcbdoc_bin.c (revision 35452) +++ altium/pcbdoc_bin.c (revision 35453) @@ -1,14 +1,9 @@ #include "pcbdoc_ascii.h" +#include "pcbdoc_bin.h" -typedef struct { - long alloced; - unsigned char *data; -} altium_buf_t; - - -int pcbdoc_bin_parse_board6(rnd_hidlib_t *hidlib, altium_tree_t *tree, ucdf_file_t *fp) +int pcbdoc_bin_parse_board6(rnd_hidlib_t *hidlib, altium_tree_t *tree, ucdf_file_t *fp, altium_buf_t *tmp) { - + return -1; } Index: altium/pcbdoc_bin.h =================================================================== --- altium/pcbdoc_bin.h (nonexistent) +++ altium/pcbdoc_bin.h (revision 35453) @@ -0,0 +1,4 @@ +typedef struct { + long alloced; + unsigned char *data; +} altium_buf_t; Index: altium/test.c =================================================================== --- altium/test.c (revision 35452) +++ altium/test.c (revision 35453) @@ -1,8 +1,9 @@ #include #include #include "pcbdoc_ascii.h" +#include "pcbdoc_bin.h" -int pcbdoc_bin_parse_board6(rnd_hidlib_t *hidlib, altium_tree_t *tree, ucdf_file_t *fp); +int pcbdoc_bin_parse_board6(rnd_hidlib_t *hidlib, altium_tree_t *tree, ucdf_file_t *fp, altium_buf_t *tmp); int main(int argc, char *argv[]) { @@ -9,8 +10,9 @@ const char *fn = "Data.dat"; FILE *f; int res; - altium_tree_t tree; - rnd_hidlib_t hidlib; + altium_tree_t tree = {0}; + rnd_hidlib_t hidlib = {0}; + altium_buf_t tmp = {0}; f = fopen(fn, "rb"); if (f == NULL) { @@ -18,7 +20,7 @@ exit(1); } - res = pcbdoc_bin_parse_board6(&hidlib, &tree, f); + res = pcbdoc_bin_parse_board6(&hidlib, &tree, f, &tmp); fclose(f);