summaryrefslogtreecommitdiffstats
path: root/tools/h5repack/h5repack_parse.c
diff options
context:
space:
mode:
authorPedro Vicente Nunes <pvn@hdfgroup.org>2004-04-02 15:52:24 (GMT)
committerPedro Vicente Nunes <pvn@hdfgroup.org>2004-04-02 15:52:24 (GMT)
commit6705762081f1bbea41037cc44973dc20d85832fc (patch)
tree0781c6d7853f74ed3d991699aa39f9ed395e1157 /tools/h5repack/h5repack_parse.c
parent9a04849fdb552678c3443e3fdcd91a6bb10e3089 (diff)
downloadhdf5-6705762081f1bbea41037cc44973dc20d85832fc.zip
hdf5-6705762081f1bbea41037cc44973dc20d85832fc.tar.gz
hdf5-6705762081f1bbea41037cc44973dc20d85832fc.tar.bz2
[svn-r8297] Purpose:
bug fix Description: the synntax of the input of h5repack conatined double quotes and spaces, which were causing problems on the parsing in AIX paralell Solution: replaced the spaces by = that is, instead of -f "GZIP 6" we have now -f GZIP=6 Platforms tested: linux solaris AIX paralell Misc. update:
Diffstat (limited to 'tools/h5repack/h5repack_parse.c')
-rw-r--r--tools/h5repack/h5repack_parse.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/tools/h5repack/h5repack_parse.c b/tools/h5repack/h5repack_parse.c
index 0f1e0d2..204adf3 100644
--- a/tools/h5repack/h5repack_parse.c
+++ b/tools/h5repack/h5repack_parse.c
@@ -18,6 +18,9 @@
#include <ctype.h>
#include "h5repack.h"
+#if 0
+#define PARSE_DEBUG
+#endif
/*-------------------------------------------------------------------------
* Function: parse_filter
@@ -34,7 +37,7 @@
* NONE, to remove the filter
*
* Examples:
- * "GZIP 6"
+ * "GZIP=6"
* "A,B:NONE"
*
* Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu
@@ -60,6 +63,10 @@ obj_list_t* parse_filter(const char *str,
obj_list_t* obj_list=NULL;
unsigned pixels_per_block;
+#if defined(PARSE_DEBUG)
+ fprintf(stderr,"%s\n",str);
+#endif
+
/* initialize compression info */
memset(filt,0,sizeof(filter_info_t));
@@ -120,9 +127,9 @@ obj_list_t* parse_filter(const char *str,
{
c = str[i];
scomp[k]=c;
- if ( c==' ' || i==len-1)
+ if ( c=='=' || i==len-1)
{
- if ( c==' ') { /*one more parameter */
+ if ( c=='=') { /*one more parameter */
scomp[k]='\0'; /*cut space */
/* here we could have 1, 2 or 3 digits */
@@ -292,7 +299,7 @@ const char* get_sfilter(H5Z_filter_t filtn)
* COMPA, to apply compact layout
*
* Example:
- * "AA,B,CDE:CHUNK 10X10"
+ * "AA,B,CDE:CHUNK=10X10"
*
* Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu
*
@@ -300,9 +307,6 @@ const char* get_sfilter(H5Z_filter_t filtn)
*
*-------------------------------------------------------------------------
*/
-
-
-
obj_list_t* parse_layout(const char *str,
int *n_objs,
pack_info_t *pack, /* info about layout needed */
@@ -412,10 +416,6 @@ obj_list_t* parse_layout(const char *str,
c = str[i];
sdim[k]=c;
k++; /*increment sdim index */
-
-#if defined PARSE_DEBUG
- printf (" i=%d c=%c ",i, c);
-#endif
if (!isdigit(c) && c!='x' && c!='N' && c!='O' && c!='N' && c!='E'){
if (obj_list) free(obj_list);