diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2006-01-23 20:48:45 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2006-01-23 20:48:45 (GMT) |
commit | 615a1fc7ec94b1c2f23fe3595033181afbf5a9e3 (patch) | |
tree | 6bc13879c04b7e71f2b45b7670ad150a9b3dfffa /tools/lib/h5tools.c | |
parent | 313102f942252d948f5eb0e9b2246f295b3b9c76 (diff) | |
download | hdf5-615a1fc7ec94b1c2f23fe3595033181afbf5a9e3.zip hdf5-615a1fc7ec94b1c2f23fe3595033181afbf5a9e3.tar.gz hdf5-615a1fc7ec94b1c2f23fe3595033181afbf5a9e3.tar.bz2 |
[svn-r11888] Purpose:
Code cleanup
Description:
Check in some of the code cleanups from working on the external link
support. (This doesn't include any of the external link features)
Platforms tested:
FreeBSD 4.11 (sleipnir)
Mac OSX.4 (amazon)
Linux 2.4
Diffstat (limited to 'tools/lib/h5tools.c')
-rw-r--r-- | tools/lib/h5tools.c | 29 |
1 files changed, 14 insertions, 15 deletions
diff --git a/tools/lib/h5tools.c b/tools/lib/h5tools.c index f5bd847..ac578c0 100644 --- a/tools/lib/h5tools.c +++ b/tools/lib/h5tools.c @@ -44,7 +44,6 @@ #define ALIGN(A,Z) ((((A) + (Z) - 1) / (Z)) * (Z)) /* global variables */ -int indent; int compound_data; FILE *rawdatastream; /* should initialize to stdout but gcc moans about it */ @@ -429,7 +428,7 @@ h5tools_ncols(const char *s) *------------------------------------------------------------------------- */ static void -h5tools_simple_prefix(FILE *stream, const h5dump_t *info, +h5tools_simple_prefix(FILE *stream, const h5tool_format_t *info, h5tools_context_t *ctx, hsize_t elmtno, int secnum) { h5tools_str_t prefix; @@ -542,7 +541,7 @@ h5tools_simple_prefix(FILE *stream, const h5dump_t *info, *------------------------------------------------------------------------- */ void -h5tools_dump_simple_data(FILE *stream, const h5dump_t *info, hid_t container, +h5tools_dump_simple_data(FILE *stream, const h5tool_format_t *info, hid_t container, h5tools_context_t *ctx/*in,out*/, unsigned flags, hsize_t nelmts, hid_t type, void *_mem) { @@ -554,7 +553,7 @@ h5tools_dump_simple_data(FILE *stream, const h5dump_t *info, hid_t container, size_t ncols = 80; /*available output width */ h5tools_str_t buffer; /*string into which to render */ int multiline; /*datum was multiline */ - hsize_t curr_pos; /* total data element position */ + hsize_t curr_pos; /* total data element position */ int elmt_counter = 0;/*counts the # elements printed. *I (ptl?) needed something that *isn't going to get reset when a new @@ -673,9 +672,9 @@ h5tools_dump_simple_data(FILE *stream, const h5dump_t *info, hid_t container, if (secnum) multiline++; - /* pass to the prefix the total position instead of the current - stripmine position i; this is necessary to print the array - indices */ + /* pass to the prefix in h5tools_simple_prefix the total position + instead of the current stripmine position i; this is necessary + to print the array indices */ curr_pos = ctx->sm_pos + i; h5tools_simple_prefix(stream, info, ctx, curr_pos, secnum); @@ -710,7 +709,7 @@ h5tools_dump_simple_data(FILE *stream, const h5dump_t *info, hid_t container, *------------------------------------------------------------------------- */ static herr_t -h5tools_dump_simple_subset(FILE *stream, const h5dump_t *info, hid_t dset, +h5tools_dump_simple_subset(FILE *stream, const h5tool_format_t *info, hid_t dset, hid_t p_type, struct subset_t *sset, int indentlevel) { @@ -877,7 +876,7 @@ done: *------------------------------------------------------------------------- */ static int -h5tools_dump_simple_dset(FILE *stream, const h5dump_t *info, hid_t dset, +h5tools_dump_simple_dset(FILE *stream, const h5tool_format_t *info, hid_t dset, hid_t p_type, int indentlevel) { hid_t f_space; /*file data space */ @@ -1014,7 +1013,7 @@ h5tools_dump_simple_dset(FILE *stream, const h5dump_t *info, hid_t dset, flags = (elmtno == 0) ? START_OF_DATA : 0; flags |= ((elmtno + hs_nelmts) >= p_nelmts) ? END_OF_DATA : 0; - /* initialize the current stripmine position; this is necessary to print the array + /* initialize the current stripmine position; this is necessary to print the array indices */ ctx.sm_pos = elmtno; @@ -1072,7 +1071,7 @@ h5tools_dump_simple_dset(FILE *stream, const h5dump_t *info, hid_t dset, *------------------------------------------------------------------------- */ static int -h5tools_dump_simple_mem(FILE *stream, const h5dump_t *info, hid_t obj_id, +h5tools_dump_simple_mem(FILE *stream, const h5tool_format_t *info, hid_t obj_id, hid_t type, hid_t space, void *mem, int indentlevel) { int i; /*counters */ @@ -1161,7 +1160,7 @@ h5tools_dump_simple_mem(FILE *stream, const h5dump_t *info, hid_t obj_id, *------------------------------------------------------------------------- */ int -h5tools_dump_dset(FILE *stream, const h5dump_t *info, hid_t dset, hid_t _p_type, +h5tools_dump_dset(FILE *stream, const h5tool_format_t *info, hid_t dset, hid_t _p_type, struct subset_t *sset, int indentlevel) { hid_t f_space; @@ -1169,7 +1168,7 @@ h5tools_dump_dset(FILE *stream, const h5dump_t *info, hid_t dset, hid_t _p_type, hid_t f_type; H5S_class_t space_type; int status = FAIL; - h5dump_t info_dflt; + h5tool_format_t info_dflt; /* Use default values */ if (!stream) @@ -1239,10 +1238,10 @@ done: *------------------------------------------------------------------------- */ int -h5tools_dump_mem(FILE *stream, const h5dump_t *info, hid_t obj_id, hid_t type, +h5tools_dump_mem(FILE *stream, const h5tool_format_t *info, hid_t obj_id, hid_t type, hid_t space, void *mem, int indentlevel) { - h5dump_t info_dflt; + h5tool_format_t info_dflt; /* Use default values */ if (!stream) |