Skip to content

Commit

Permalink
Add a buildtime print
Browse files Browse the repository at this point in the history
Make it clearer which records are not recognised
  • Loading branch information
ibmmqmet committed Jun 6, 2016
1 parent 5ddb8e5 commit 18cb315
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 3 deletions.
Binary file modified bin/aix/convH
Binary file not shown.
Binary file modified bin/aix/mqsmfcsv
Binary file not shown.
Binary file modified bin/linux/convH
Binary file not shown.
Binary file modified bin/linux/mqsmfcsv
Binary file not shown.
Binary file modified bin/win/mqsmfcsv.exe
Binary file not shown.
11 changes: 9 additions & 2 deletions src/mqsmf.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ int main( int argc, char *argv[] )
qwhs *pqwhs;

BOOL error = FALSE;
BOOL knownSubType = TRUE;
int c;

int sectionCount;
Expand Down Expand Up @@ -163,6 +164,7 @@ int main( int argc, char *argv[] )
/******************************************************************/
/* Parse command-line parameters */
/******************************************************************/
printf("MQ SMF CSV - Build %s %s\n",__DATE__,__TIME__);
while((c = mqgetopt(argc, argv, "ad:h:i:m:o:rt:")) != EOF)
{
switch(c)
Expand Down Expand Up @@ -454,6 +456,7 @@ int main( int argc, char *argv[] )
/* the triplet[].n values, but we know that some of the entries */
/* consist always of a single entry. */
/*********************************************************************/
knownSubType = TRUE;
switch(recordType)
{
/*********************************************************************/
Expand All @@ -468,7 +471,6 @@ int main( int argc, char *argv[] )
/* Processing 115 records */
/*********************************************************************/
case 115:
Count115[recordSubType]++;
switch(recordSubType)
{
case 1:
Expand Down Expand Up @@ -596,18 +598,20 @@ int main( int argc, char *argv[] )
break;

default:
knownSubType = FALSE;
sprintf(tmpHead,"Unknown SMF 115 subtype %d",recordSubType);
printDEBUG(tmpHead, dataBuf,offset);
printf("%s\n",tmpHead);
break;
}
if (knownSubType)
Count115[recordSubType]++;
break;

/*********************************************************************/
/* Processing 116 records */
/*********************************************************************/
case 116:
Count116[recordSubType]++;
switch(recordSubType)
{
case 0:
Expand Down Expand Up @@ -673,11 +677,14 @@ int main( int argc, char *argv[] )
break;

default:
knownSubType = FALSE;
sprintf(tmpHead, "Unknown subtype %d for 116 records");
printDEBUG(tmpHead, dataBuf,offset);
printf("%s\n",tmpHead);
break;
}
if (knownSubType)
Count116[recordSubType]++;
break;


Expand Down
2 changes: 1 addition & 1 deletion testing/testall.bat
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
set INDIR=y:\metaylor\mf\L\smf
set INDIR=y:\metaylor\mf\L\mq-smf-csv\src
set OUTDIR=c:\temp\smf\out

mkdir %OUTDIR%
Expand Down

0 comments on commit 18cb315

Please sign in to comment.