[cig-commits] commit: Cleaned-up 'unused variables' which causes compile warnings.

Mercurial hg at geodynamics.org
Mon Feb 1 15:33:12 PST 2010


changeset:   746:75b2f830b182
branch:      pcu_rejig
user:        JericoRevote
date:        Fri Dec 18 16:41:37 2009 +1100
files:       Base/Container/tests/LinkedListSuite.c Base/Container/tests/PtrSetSuite.c Base/Container/tests/RangeSetSuite.c Base/Context/src/AbstractContext.c Base/Context/src/DynamicVC.c Base/Context/src/Variable.c Base/Context/tests/VariableAllVC_Suite.c Base/Extensibility/src/ModulesManager.c Base/Extensibility/src/PluginsManager.c Base/Foundation/src/Memory.c Base/Foundation/src/MemoryReport.c Base/Foundation/tests/MemorySuite.c Base/Foundation/tests/TimeMonitorSuite.c Base/IO/src/IO_Handler.c Base/IO/src/MPIStream.c Base/IO/src/XML_IO_Handler.c Base/IO/tests/DictionarySuite.c Base/IO/tests/IO_HandlerSuite.c Base/IO/tests/JournalSuite.c
description:
Cleaned-up 'unused variables' which causes compile warnings.


diff -r 9c3235727789 -r 75b2f830b182 Base/Container/tests/LinkedListSuite.c
--- a/Base/Container/tests/LinkedListSuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Container/tests/LinkedListSuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -117,7 +117,6 @@ void LinkedListSuite_Teardown( LinkedLis
 
 
 void LinkedListSuite_TestInsert( LinkedListSuiteData* data ) {
-   LinkedList*       numList = NULL;
    Index             ii = 0;
    LinkedListNode*   currNode=NULL;   
 
diff -r 9c3235727789 -r 75b2f830b182 Base/Container/tests/PtrSetSuite.c
--- a/Base/Container/tests/PtrSetSuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Container/tests/PtrSetSuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -83,7 +83,6 @@ static void markArray( void* setItem, vo
 
 void PtrSetSuite_TestInsertTraverse( PtrSetSuiteData* data ) {
    unsigned    ptr_I;
-   unsigned*   ptr;
 
    for( ptr_I = 0; ptr_I < NUM_ITEMS; ptr_I++ ) {
       Set_Insert( data->setA, &data->dataArray[ptr_I] );
diff -r 9c3235727789 -r 75b2f830b182 Base/Container/tests/RangeSetSuite.c
--- a/Base/Container/tests/RangeSetSuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Container/tests/RangeSetSuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -62,7 +62,6 @@ void RangeSetSuite_Teardown( RangeSetSui
 
 
 void RangeSetSuite_TestIndices( RangeSetSuiteData* data ) {
-   Bool      result = True;
    unsigned   nInds = NUM_ITEMS;
    unsigned   inds[NUM_ITEMS];
    unsigned   nDstInds, *dstInds;
@@ -90,7 +89,6 @@ void RangeSetSuite_TestIndices( RangeSet
 
 
 void RangeSetSuite_TestRanges( RangeSetSuiteData* data ) {
-   Bool              result = True;
    unsigned          nInds = NUM_ITEMS;
    unsigned          inds[NUM_ITEMS];
    unsigned          nDstInds, *dstInds;
diff -r 9c3235727789 -r 75b2f830b182 Base/Context/src/AbstractContext.c
--- a/Base/Context/src/AbstractContext.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Context/src/AbstractContext.c	Fri Dec 18 16:41:37 2009 +1100
@@ -52,6 +52,7 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <time.h>
+#include <unistd.h>
 
 #if defined(READ_HDF5) || defined(WRITE_HDF5)
 #include <hdf5.h>
@@ -900,6 +901,7 @@ void _AbstractContext_LoadTimeInfoFromCh
 	
    timeInfoFileNamePart = Context_GetCheckPointReadPrefixString( self );
 #ifdef WRITE_HDF5
+	timeInfoFile = NULL;
    Stg_asprintf( &timeInfoFileName, "%stimeInfo.%.5u.h5", timeInfoFileNamePart, self->restartTimestep );
 	 
 	/* Open the file and data set. */
@@ -971,6 +973,7 @@ void _AbstractContext_SaveTimeInfo( void
 	if ( self->rank == 0 ) {
    timeInfoFileNamePart = Context_GetCheckPointWritePrefixString( self );
 #ifdef WRITE_HDF5
+	timeInfoFile = NULL;
    Stg_asprintf( &timeInfoFileName, "%stimeInfo.%.5u.h5", timeInfoFileNamePart, self->timeStep );
 	
 	/* Create parallel file property list. */
@@ -1088,9 +1091,8 @@ Bool AbstractContext_CheckPointExists( v
 }
 
 char* Context_GetCheckPointReadPrefixString( void* context ) {
-	AbstractContext*       self = context;	
-	Index                  readStrLen = 0;
-	char*                  readPathString = NULL;
+	AbstractContext*	self = context;	
+	char*					readPathString = NULL;
 
    if ( self->checkpointAppendStep ) {
       if ( strlen(self->checkPointPrefixString) > 0 ) {
@@ -1112,9 +1114,8 @@ char* Context_GetCheckPointReadPrefixStr
 }
 
 char* Context_GetCheckPointWritePrefixString( void* context ) {
-	AbstractContext*       self = context;	
-	Index                  writeStrLen = 0;
-	char*                  writePathString = NULL;
+	AbstractContext*	self = context;	
+	char*					writePathString = NULL;
 
    if ( self->checkpointAppendStep ) {
       if ( strlen(self->checkPointPrefixString) > 0 ) {
diff -r 9c3235727789 -r 75b2f830b182 Base/Context/src/DynamicVC.c
--- a/Base/Context/src/DynamicVC.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Context/src/DynamicVC.c	Fri Dec 18 16:41:37 2009 +1100
@@ -150,7 +150,7 @@ void _DynamicVC_Destroy( void* vc, void*
 
 	NewClass_Delete( self->vcMap );
 
-	__VariableCondition( self, data );
+	_VariableCondition_Destroy( self, data );
 }
 
 void _DynamicVC_ReadDictionary( void* vc, void* dict ) {
diff -r 9c3235727789 -r 75b2f830b182 Base/Context/src/Variable.c
--- a/Base/Context/src/Variable.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Context/src/Variable.c	Fri Dec 18 16:41:37 2009 +1100
@@ -311,7 +311,7 @@ void _Variable_Init(
 	Bool							allocateSelf,
 	Variable_Register*		vr )
 {
-	Stream* errorStream = Journal_Register( Error_Type, self->type );
+	/*Stream* errorStream = Journal_Register( Error_Type, self->type );*/
 
 	/* General and Virtual info should already be set */
 	
diff -r 9c3235727789 -r 75b2f830b182 Base/Context/tests/VariableAllVC_Suite.c
--- a/Base/Context/tests/VariableAllVC_Suite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Context/tests/VariableAllVC_Suite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -77,7 +77,6 @@ void VariableAllVC_Suite_CreateDictEntri
 
 
 void VariableAllVC_Suite_Setup( VariableAllVC_SuiteData* data ) {
-
    data->arraySize = 10;
    data->testArray = Memory_Alloc_Array( double, data->arraySize, "test" );
 
@@ -99,8 +98,6 @@ void VariableAllVC_Suite_Setup( Variable
 
 
 void VariableAllVC_Suite_Teardown( VariableAllVC_SuiteData* data ) {
-   Index    ii=0;
-
    Stg_Class_Delete(data->vr);
    Stg_Class_Delete(data->conFunc_Register);
    Stg_Class_Delete(data->dict);
@@ -108,12 +105,12 @@ void VariableAllVC_Suite_Teardown( Varia
    Memory_Free( data->testArray );
    Stg_Class_Delete( data->var );
 
-   Stg_Class_Delete(data->vc);
+   _Stg_Component_Delete(data->vc);
 }
 
 
 void VariableAllVC_Suite_TestIsCondition( VariableAllVC_SuiteData* data ) {
-   Index      node_I=0;
+   Index node_I=0;
 
    for (node_I = 0; node_I < data->arraySize; node_I++) {
       pcu_check_true( True == VariableCondition_IsCondition(data->vc, node_I, 0) );
@@ -122,7 +119,7 @@ void VariableAllVC_Suite_TestIsCondition
 
 
 void VariableAllVC_Suite_TestGetValueIndex( VariableAllVC_SuiteData* data ) {
-   Index      node_I=0;
+   Index node_I=0;
 
    for (node_I = 0; node_I < data->arraySize; node_I++) {
       pcu_check_true( 0 == VariableCondition_GetValueIndex(data->vc, node_I, 0) );
@@ -131,7 +128,7 @@ void VariableAllVC_Suite_TestGetValueInd
 
 
 void VariableAllVC_Suite_TestApply( VariableAllVC_SuiteData* data ) {
-   Index      var_I=0, node_I=0;
+   Index node_I=0;
    
    VariableCondition_Apply(data->vc, NULL);
 
diff -r 9c3235727789 -r 75b2f830b182 Base/Extensibility/src/ModulesManager.c
--- a/Base/Extensibility/src/ModulesManager.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Extensibility/src/ModulesManager.c	Fri Dec 18 16:41:37 2009 +1100
@@ -183,20 +183,20 @@ Name ModulesManager_GetModuleName( void*
 }
 
 void ModulesManager_Load( void* modulesManager, void* _dictionary, Name contextName ) {
-	ModulesManager*			self 		= (ModulesManager*)modulesManager;
-	Dictionary*			dictionary 	= (Dictionary*)_dictionary;
-	unsigned int			entryCount;
-	unsigned int			entry_I;
-	Dictionary_Entry_Value*		modulesVal;
+	ModulesManager*			self = (ModulesManager*)modulesManager;
+	Dictionary*					dictionary = (Dictionary*)_dictionary;
+	unsigned int				entryCount;
+	unsigned int				entry_I;
+	Dictionary_Entry_Value*	modulesVal;
 
 	/* First add the directory list onto LD_LIBRARY_PATH so that it can potentially
 	 * resolve the unknown symbols */
+#ifndef NOSHARED
 	char* curEnvPath;
 	char* newEnvPath;
-	Index newEnvPathLength = 0;
+	Index newEnvPathLength;
 	Index dir_I;
-	
-#ifndef NOSHARED
+
 	if( dictionary ) {
 		Dictionary_Entry_Value* localLibDirList = Dictionary_Get( dictionary, "LD_LIBRARY_PATH" );
 		if( localLibDirList ) {
diff -r 9c3235727789 -r 75b2f830b182 Base/Extensibility/src/PluginsManager.c
--- a/Base/Extensibility/src/PluginsManager.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Extensibility/src/PluginsManager.c	Fri Dec 18 16:41:37 2009 +1100
@@ -29,6 +29,7 @@
 **~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~*/
 
 #include <stdarg.h>
+#include <string.h>
 #include "Base/Foundation/Foundation.h"
 #include "Base/IO/IO.h"
 #include "Base/Container/Container.h"
@@ -140,10 +141,12 @@ void PluginsManager_RemoveAllFromCompone
 }
 
 Bool _PluginsManager_CheckContext( void* pluginsManager, Dictionary_Entry_Value* modulesVal, unsigned int entry_I, Name contextName ) {
-	PluginsManager* 	self 		= (PluginsManager*)pluginsManager;
-	Dictionary_Entry_Value*	pluginDEV	= Dictionary_Entry_Value_GetElement( modulesVal, entry_I );
-	Dictionary*		pluginDict;
-	Name			componentName;
+	PluginsManager*			self;
+	Dictionary_Entry_Value*	pluginDEV = Dictionary_Entry_Value_GetElement( modulesVal, entry_I );
+	Dictionary*					pluginDict;
+	Name							componentName;
+
+	self = (PluginsManager*)pluginsManager;
 
 	pluginDict = Dictionary_Entry_Value_AsDictionary( pluginDEV );
 	if( !pluginDict )
@@ -158,10 +161,12 @@ Bool _PluginsManager_CheckContext( void*
 }
 
 Name _PluginsManager_GetModuleName( void* pluginsManager, Dictionary_Entry_Value* moduleVal, unsigned int entry_I ) {
-	PluginsManager* 	self 		= (PluginsManager*)pluginsManager;
-	Dictionary_Entry_Value*	pluginDEV	= Dictionary_Entry_Value_GetElement( moduleVal, entry_I );
-	Dictionary*		pluginDict 	= Dictionary_Entry_Value_AsDictionary( pluginDEV );
-	Name			pluginName 	= Dictionary_GetString( pluginDict, "Type" );
+	PluginsManager*			self;
+	Dictionary_Entry_Value*	pluginDEV = Dictionary_Entry_Value_GetElement( moduleVal, entry_I );
+	Dictionary*					pluginDict = Dictionary_Entry_Value_AsDictionary( pluginDEV );
+	Name							pluginName = Dictionary_GetString( pluginDict, "Type" );
+
+	self = (PluginsManager*)pluginsManager;
 
 	return pluginName;	
 }
diff -r 9c3235727789 -r 75b2f830b182 Base/Foundation/src/Memory.c
--- a/Base/Foundation/src/Memory.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Foundation/src/Memory.c	Fri Dec 18 16:41:37 2009 +1100
@@ -1206,9 +1206,10 @@ void* _Memory_Realloc_3DArrayAs1D_Func(
 
 
 /* This function should only be called on ptrs allocated by StGermain's Memory routines */
-void _Memory_Free_Func( void* ptr )
-{
+void _Memory_Free_Func( void* ptr ) {
+	#ifdef MEMORY_STATS
 	MemoryPointer* memoryPointer = NULL;
+	#endif
 
 	if( !ptr ) return;
 	
diff -r 9c3235727789 -r 75b2f830b182 Base/Foundation/src/MemoryReport.c
--- a/Base/Foundation/src/MemoryReport.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Foundation/src/MemoryReport.c	Fri Dec 18 16:41:37 2009 +1100
@@ -61,10 +61,8 @@ MemoryReport* MemoryReport_New( ) {
 }
 	
 
-void _MemoryReport_Init( MemoryReport* memoryReport )
-{
-	char     reportQueryName[1000];
-	Index    ii=0;
+void _MemoryReport_Init( MemoryReport* memoryReport ) {
+	Index ii=0;
 
 	memoryReport->groupCount = 0;
 	memoryReport->groupSize = MEMORYREPORT_SIZE;
@@ -78,13 +76,11 @@ void _MemoryReport_Init( MemoryReport* m
 	}
    
 	memoryReport->memoryManager = stgMemory;   /* Use this as the default, unless user overrides */
-	
 	memoryReport->reportField = MemoryField_New( "Report Query:" );
 }
 	
 
-void MemoryReport_Delete( MemoryReport* memoryReport )
-{
+void MemoryReport_Delete( MemoryReport* memoryReport ) {
 	Index i;
 	
 	MemoryField_Delete( memoryReport->reportField );
diff -r 9c3235727789 -r 75b2f830b182 Base/Foundation/tests/MemorySuite.c
--- a/Base/Foundation/tests/MemorySuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Foundation/tests/MemorySuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -61,7 +61,9 @@ void MemorySuite_Test2DArray( MemorySuit
    double**       array2d = NULL;
    Index          ii = 0;
    Index          jj = 0;
+	#ifdef MEMORY_STATS
    MemoryPointer* memoryPtr;
+	#endif
 
    array2d = Memory_Alloc_2DArray_Unnamed( double, 2, 3 );
    pcu_check_true( NULL != array2d );
diff -r 9c3235727789 -r 75b2f830b182 Base/Foundation/tests/TimeMonitorSuite.c
--- a/Base/Foundation/tests/TimeMonitorSuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/Foundation/tests/TimeMonitorSuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -48,10 +48,6 @@ void TimeMonitorSuite_Teardown( TimeMoni
 }
 
 void TimeMonitorSuite_TestTimingPeriod( TimeMonitorSuiteData* data ) {
-   Stream*           timeMonitorStream = NULL;
-   char*             timeMonitorOutputFilename = "./TimeMonitorSuite_TestOutput.txt";
-   FILE*             timeMonitorOutputFile = NULL;
-   char*             infoString = NULL;
    #define           MAXLINE 1000
    TimeMonitorData   tmData;
    Stg_TimeMonitor*  tm=NULL;
@@ -65,9 +61,9 @@ void TimeMonitorSuite_TestTimingPeriod( 
    sleep( 2 );
    Stg_TimeMonitor_End( tm, &tmData );
 
-   pcu_check_true( 2.95 < tmData.totalSinceInit < 3.05 );
-   pcu_check_true( 1.95 < tmData.dt < 2.05 );
-   pcu_check_true( 1.95 < tmData.aveProcDt < 2.05 );
+   pcu_check_true( ( 2.95 < tmData.totalSinceInit ) && ( tmData.totalSinceInit < 3.05 ) );
+   pcu_check_true( ( 1.95 < tmData.dt ) && ( tmData.dt < 2.05 ) );
+   pcu_check_true( ( 1.95 < tmData.aveProcDt ) && ( tmData.aveProcDt < 2.05 ) );
    percentOfTotalCalc = tmData.aveProcDt / tmData.totalSinceInit * 100;
    pcu_check_true( fabs( percentOfTotalCalc - tmData.percentTM_ofTotal ) < 0.01 );
    pcu_check_true( tmData.criterionPassed == True );
@@ -75,7 +71,6 @@ void TimeMonitorSuite_TestTimingPeriod( 
    Stg_TimeMonitor_Delete( tm );
 }
 
-
 void TimeMonitorSuite( pcu_suite_t* suite ) {
    pcu_suite_setData( suite, TimeMonitorSuiteData );
    pcu_suite_setFixtures( suite, TimeMonitorSuite_Setup, TimeMonitorSuite_Teardown );
diff -r 9c3235727789 -r 75b2f830b182 Base/IO/src/IO_Handler.c
--- a/Base/IO/src/IO_Handler.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/IO/src/IO_Handler.c	Fri Dec 18 16:41:37 2009 +1100
@@ -449,9 +449,8 @@ void _get_XML(void* ioHandler, char* arg
 
 
 Index IO_Handler_ReadAllFromCommandLine( void* ioHandler, int argc, char* argv[], Dictionary* dictionary ) {
-	Index       filesRead = 0;
-	Index arg_I;
-	IO_Handler* self;	
+	Index filesRead = 0;
+
 	_get_XML( ioHandler, argv, argc );
 	filesRead = IO_Handler_ReadAllFilesFromCommandLine( ioHandler, argc, argv, dictionary );
 	Dictionary_ReadAllParamFromCommandLine( dictionary, argc, argv );
@@ -461,7 +460,8 @@ Index IO_Handler_ReadAllFromCommandLine(
 
 
 Index IO_Handler_ReadAllFromCommandLineForceSource( void* ioHandler, int argc, char* argv[], Dictionary* dictionary ) {
-	Index       filesRead = 0;
+	Index filesRead = 0;
+
 	filesRead = IO_Handler_ReadAllFilesFromCommandLineForceSource( ioHandler, argc, argv, dictionary );
 	Dictionary_ReadAllParamFromCommandLine( dictionary, argc, argv );
 
diff -r 9c3235727789 -r 75b2f830b182 Base/IO/src/MPIStream.c
--- a/Base/IO/src/MPIStream.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/IO/src/MPIStream.c	Fri Dec 18 16:41:37 2009 +1100
@@ -194,7 +194,6 @@ Bool _MPIStream_SetFile( Stream* stream,
 
 Bool MPIStream_SetOffset( Stream* stream, SizeT sizeToWrite, MPI_Comm communicator ) {
 	MPI_Offset    offset    = 0;
-	MPI_Status    status;
 	int           rank;
 	int           nproc;
 	unsigned int  localSizeToWrite;
diff -r 9c3235727789 -r 75b2f830b182 Base/IO/src/XML_IO_Handler.c
--- a/Base/IO/src/XML_IO_Handler.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/IO/src/XML_IO_Handler.c	Fri Dec 18 16:41:37 2009 +1100
@@ -745,6 +745,7 @@ static xmlNodePtr _XML_IO_Handler_OpenCh
 	return rootElement;
 }
 
+#if 0
 static void _processNode(xmlTextReaderPtr reader) {
 	const xmlChar *name, *value;
 
@@ -769,13 +770,14 @@ static void _processNode(xmlTextReaderPt
 			printf(" %s\n", value);
 	}
 }
+#endif
 
 static void _XML_IO_Handler_ValidateFile( XML_IO_Handler* self, const char* filename ) {
-	xmlTextReaderPtr reader;
-	int ret, valid;
-
 	#ifdef LIBXML_VERSION 
 	#if LIBXML_VERSION == 20631
+	xmlTextReaderPtr reader;
+	//int valid;
+	int ret;
 
 	reader = xmlNewTextReaderFilename( filename );
 
@@ -854,7 +856,6 @@ static void _XML_IO_Handler_OpenBuffer( 
 
 Bool _XML_IO_Handler_Check( XML_IO_Handler* self, xmlDocPtr currDoc ) {
 	xmlNodePtr	rootElement = NULL;
-	xmlNodePtr	cur = NULL;
 	
 	rootElement = xmlDocGetRootElement( self->currDoc );
 	if ( !rootElement ) {
@@ -1191,8 +1192,6 @@ static void _XML_IO_Handler_ParseList( X
 	xmlChar* childrenMergeTypeStr = xmlGetProp( cur, CHILDRENMERGETYPE_ATTR );
 	xmlChar* spaceStrippedName = NULL;
 	xmlChar* spaceStrippedSourceFile = NULL;
-	xmlChar* spaceStrippedMergeType = NULL;
-	xmlChar* spaceStrippedChildrenMergeType = NULL;
 	Dictionary_Entry_Value* newList = NULL;
 	Dictionary_MergeType mergeType = defaultMergeType;
 	Dictionary_MergeType childrenMergeType = Dictionary_MergeType_Append;
@@ -1451,8 +1450,6 @@ static void _XML_IO_Handler_ParseStruct(
 	xmlChar* childrenMergeTypeStr = xmlGetProp( cur, CHILDRENMERGETYPE_ATTR );
 	xmlChar* spaceStrippedName = NULL;
 	xmlChar* spaceStrippedSourceFile = NULL;
-	xmlChar* spaceStrippedMergeType = NULL;
-	xmlChar* spaceStrippedChildrenMergeType = NULL;
 	Dictionary_Entry_Value* newStruct = NULL;
 	Dictionary_MergeType mergeType = defaultMergeType;
 	Dictionary_MergeType childrenMergeType = IO_Handler_DefaultChildrenMergeType;
@@ -1516,7 +1513,6 @@ static void _XML_IO_Handler_ParseParamet
 	Dictionary_Entry_Value_Type dictValueType = _XML_IO_Handler_GetDictValueType( self, (char*) type );
 	xmlChar* spaceStrippedName = NULL;
 	xmlChar* spaceStrippedSourceFile = NULL;
-	xmlChar* spaceStrippedMergeType = NULL;
 	xmlChar* spaceStrippedType = NULL;
 	xmlChar* strippedVal = NULL;
 	Dictionary_MergeType mergeType = defaultMergeType;
diff -r 9c3235727789 -r 75b2f830b182 Base/IO/tests/DictionarySuite.c
--- a/Base/IO/tests/DictionarySuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/IO/tests/DictionarySuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -248,8 +248,6 @@ void DictionarySuite_TestSet( Dictionary
    Dictionary_Entry_Value* currValue;
    Dictionary_Entry_Value* listValue;
    double                  newVal1 = 34.3, newVal2 = 38.9;
-   Dictionary_Entry_Value* yValue;
-   Dictionary_Entry_Value* testStruct;
    Index                   ii=0;
 
    DictionarySuite_PopulateDictWithTestValues( data->dict, data->testDD );
diff -r 9c3235727789 -r 75b2f830b182 Base/IO/tests/IO_HandlerSuite.c
--- a/Base/IO/tests/IO_HandlerSuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/IO/tests/IO_HandlerSuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -34,6 +34,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
+#include <unistd.h>
 #include <sys/stat.h>
 #include <sys/types.h>
 #include <mpi.h>
@@ -55,8 +56,8 @@ typedef struct {
    Dictionary*                      dict1;
    Dictionary*                      dict2;
    DictionarySuite_TestDictData*    testDD;
-   Index                            rank;
-   Index                            nProcs;
+   int										rank;
+   int										nProcs;
    MPI_Comm                         comm;
 } IO_HandlerSuiteData;
 
@@ -168,7 +169,6 @@ void IO_HandlerSuite_TestWriteReadNormal
 
 /* Similar to above test, except test we can write out an empty Dictionary, then read in */
 void IO_HandlerSuite_TestWriteReadEmpty( IO_HandlerSuiteData* data ) {
-   Index          ii;
    const char*    xmlTestFilename = "empty.xml";
    FILE*          testFile = NULL;
    const int      MAXLINE = 1000;
@@ -237,7 +237,6 @@ void IO_HandlerSuite_TestWriteExplicitTy
 
 
 void IO_HandlerSuite_TestReadWhitespaceEntries( IO_HandlerSuiteData* data ) {
-   Index             ii;
    const char*       testFilename = "xmlTest-whitespaces.xml";
    char*             whiteSpacesEntry = NULL;
    const char*       testKey = "spacedKey";
@@ -275,7 +274,6 @@ void IO_HandlerSuite_TestReadWhitespaceE
 /* Note: it'd be good to use the PCU input fule capabilities, but unfortunately Scons glob doesn't seem to support
  * subdirectories currently. */
 void IO_HandlerSuite_TestReadIncludedFile( IO_HandlerSuiteData* data ) {
-   Index             ii;
    const char*       testFilename = "xmlTest-include.xml";
    const char*       testIncludedFilename = "xmlTest-included.xml";
    const char*       testSearchPathSubdir = "./testXML-subdir";
@@ -358,14 +356,11 @@ void IO_HandlerSuite_TestReadRawDataEntr
    const int         list1EntryCount = 2;
    const int         list1Vals[2][3] = { {1, 3, 6}, {2, 9, 14} };
    const char*       list2Name = "boundary_conditions2";
-   const int         list2CompCount = 5;
    const int         list2EntryCount = 3;
    const char*       list2CompNames[5] = {"side", "xval", "yval", "zval", "active"};
-   const char*       list2CompTypes[5] = {"string", "int", "int", "int", "bool"};
    const char*       list2StringVals[3] = {"top", "bottom", "left"};
    const int         list2CoordVals[3][3] = { {4,5,8}, {3,5,9}, {9,3,4} };
    const Bool        list2BoolVals[3] = { True, False, True };
-   const char*       list2BoolValStrings[3] = { "True", "False", "1" };
    Index             rank_I;
 
    testFilename = Memory_Alloc_Array_Unnamed( char, pcu_filename_inputLen( "xmlTest-rawData.xml" ) );
@@ -509,11 +504,6 @@ void IO_HandlerSuite_TestReadDuplicateEn
    Dictionary_Entry_Value* structDev = NULL;
    Dictionary_Entry_Value* elementDev = NULL;
    Dictionary*             structDict = NULL;
-   char                    struct1Entry[10000];
-   char                    struct2Entry[10000];
-   char*                   testEntries = NULL;
-   char                    xmlLine[1000];
-   Index                   rank_I;
 
    /* Only do this test for processor 0, to avoid probs with multiple opens */
    if ( data->rank != 0 ) return;
@@ -610,13 +600,12 @@ void IO_HandlerSuite_TestReadDuplicateEn
 
 
 void IO_HandlerSuite_TestReadNonExistent( IO_HandlerSuiteData* data ) {
-   char*          errorFilename;
-   char*          notExistFilename = "I_Dont_Exist.xml";
-   FILE*          errorFile;
-   #define        MAXLINE 1000
-   char           errorLine[MAXLINE];
-   char           expectedErrorMsg[MAXLINE];
-   Index          rank_I;
+   char*		errorFilename;
+   char*		notExistFilename = "I_Dont_Exist.xml";
+   FILE*		errorFile;
+   #define	MAXLINE 1000
+   char		errorLine[MAXLINE];
+   char		expectedErrorMsg[MAXLINE];
 
    Stg_asprintf( &errorFilename, "./errorMsg-NonExist-%d.txt", data->rank );
    Stream_RedirectFile( Journal_Register( Error_Type, XML_IO_Handler_Type ), errorFilename );
@@ -640,9 +629,9 @@ void IO_HandlerSuite_TestReadNonExistent
 
 
 void IO_HandlerSuite_TestReadInvalid( IO_HandlerSuiteData* data ) {
-   char              invalidXMLFilename[PCU_PATH_MAX];
-   char              expectedErrorFilename[PCU_PATH_MAX];
-   const char*       errorFilename = "errorMsg-Invalid.txt";
+   char			invalidXMLFilename[PCU_PATH_MAX];
+   char			expectedErrorFilename[PCU_PATH_MAX];
+   const char*	errorFilename = "errorMsg-Invalid.txt";
 
    pcu_filename_input( "Invalid.xml", invalidXMLFilename );
    pcu_filename_expected( errorFilename, expectedErrorFilename );
diff -r 9c3235727789 -r 75b2f830b182 Base/IO/tests/JournalSuite.c
--- a/Base/IO/tests/JournalSuite.c	Wed Dec 16 16:07:06 2009 +1100
+++ b/Base/IO/tests/JournalSuite.c	Fri Dec 18 16:41:37 2009 +1100
@@ -407,7 +407,6 @@ void JournalSuite_TestShortcuts( Journal
    double       floatValue    = 2.173425;
    int          intValue      = 3;
    unsigned int uintValue     = 3980;
-   int          char_I;
    char         charValue     = 'V';
    double       doubleArray[] = { 10.23, 393.1, -89, 1231 };        
    Index        uintArray[]   = { 10, 2021, 231, 2, 3, 4, 55 };



More information about the CIG-COMMITS mailing list