summaryrefslogtreecommitdiff
path: root/Tests/LoadCommandOneConfig
diff options
context:
space:
mode:
authorBill Hoffman <bill.hoffman@kitware.com>2004-05-03 08:52:03 -0400
committerBill Hoffman <bill.hoffman@kitware.com>2004-05-03 08:52:03 -0400
commit781a1eaaf9fbb103a750194ff0fd7fde45db6d8a (patch)
tree86ffdd8a7670831032fdfb367e1b3402262e8092 /Tests/LoadCommandOneConfig
parentee9f9255099e5de585ca88ae104a33522e6a4dd6 (diff)
downloadcmake-781a1eaaf9fbb103a750194ff0fd7fde45db6d8a.tar.gz
ENH: fix warnings in test
Diffstat (limited to 'Tests/LoadCommandOneConfig')
-rw-r--r--Tests/LoadCommandOneConfig/CMakeCommands/cmTestCommand.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/Tests/LoadCommandOneConfig/CMakeCommands/cmTestCommand.c b/Tests/LoadCommandOneConfig/CMakeCommands/cmTestCommand.c
index cb3fe1f7aa..460ee4bccd 100644
--- a/Tests/LoadCommandOneConfig/CMakeCommands/cmTestCommand.c
+++ b/Tests/LoadCommandOneConfig/CMakeCommands/cmTestCommand.c
@@ -13,7 +13,8 @@ typedef struct
static int InitialPass(void *inf, void *mf, int argc, char *argv[])
{
char* file;
- const char* str;
+ char* str;
+ const char* cstr;
char buffer[1024];
void *source_file;
cmLoadedCommandInfo *info = (cmLoadedCommandInfo *)inf;
@@ -93,19 +94,19 @@ static int InitialPass(void *inf, void *mf, int argc, char *argv[])
info->CAPI->AddDefineFlag(mf, "-DADDED_DEFINITION");
source_file = info->CAPI->CreateSourceFile();
- str = info->CAPI->SourceFileGetSourceName(source_file);
- sprintf(buffer, "Shold be empty (source file name): [%s]", str);
+ cstr = info->CAPI->SourceFileGetSourceName(source_file);
+ sprintf(buffer, "Shold be empty (source file name): [%s]", cstr);
info->CAPI->DisplaySatus(mf, buffer);
- str = info->CAPI->SourceFileGetFullPath(source_file);
- sprintf(buffer, "Shold be empty (source file full path): [%s]", str);
+ cstr = info->CAPI->SourceFileGetFullPath(source_file);
+ sprintf(buffer, "Shold be empty (source file full path): [%s]", cstr);
info->CAPI->DisplaySatus(mf, buffer);
if ( info->CAPI->SourceFileGetPropertyAsBool(source_file, "SOME_PROPERTY") )
{
info->CAPI->SetError(mf, "Property SOME_PROPERTY should not be defined");
return 0;
}
- str = info->CAPI->SourceFileGetProperty(source_file, "ABSTRACT");
- sprintf(buffer, "Shold be 0 (source file abstract property): [%p]", str);
+ cstr = info->CAPI->SourceFileGetProperty(source_file, "ABSTRACT");
+ sprintf(buffer, "Shold be 0 (source file abstract property): [%p]", cstr);
info->CAPI->DisplaySatus(mf, buffer);
info->CAPI->DestroySourceFile(source_file);