attract gcc's attention to some printf format strings (for type checking)
This commit is contained in:
parent
eb06eeb4d9
commit
d602e0b75c
|
|
@ -1,3 +1,10 @@
|
|||
2010-11-23 Robert Larice
|
||||
* src/ciderlib/oned/oneprint.c ,
|
||||
* src/ciderlib/support/globals.c ,
|
||||
* src/ciderlib/support/mater.c ,
|
||||
* src/ciderlib/twod/twoprint.c :
|
||||
attract gcc's attention to some printf format strings (for type checking)
|
||||
|
||||
2010-11-23 Robert Larice
|
||||
* src/frontend/inpcom.c ,
|
||||
* src/frontend/plotting/grid.c :
|
||||
|
|
|
|||
|
|
@ -326,8 +326,8 @@ struct MatrixElement {
|
|||
void
|
||||
ONEmemStats(FILE *file, ONEdevice *pDevice)
|
||||
{
|
||||
static char *memFormat = "%-20s%10d%10d\n";
|
||||
/* static char *sumFormat = "%20s %-10d\n";*/
|
||||
static const char memFormat[] = "%-20s%10d%10d\n";
|
||||
/* static const char sumFormat[] = "%20s %-10d\n";*/
|
||||
unsigned int size;
|
||||
unsigned int memory;
|
||||
ONEmaterial *pMaterial;
|
||||
|
|
@ -405,7 +405,7 @@ ONEmemStats(FILE *file, ONEdevice *pDevice)
|
|||
void
|
||||
ONEcpuStats(FILE *file, ONEdevice *pDevice)
|
||||
{
|
||||
static char *cpuFormat = "%-20s%10g%10g%10g%10g%10g\n";
|
||||
static const char cpuFormat[] = "%-20s%10g%10g%10g%10g%10g\n";
|
||||
ONEstats *pStats = pDevice->pStats;
|
||||
double total;
|
||||
int iTotal;
|
||||
|
|
|
|||
|
|
@ -132,8 +132,8 @@ void GLOBgetGlobals(GLOBvalues *values)
|
|||
|
||||
void GLOBprnGlobals(FILE *file, GLOBvalues *values)
|
||||
{
|
||||
static char *tabformat = "%12s: % .4e %-12s\t";
|
||||
static char *newformat = "%12s: % .4e %-12s\n";
|
||||
static const char tabformat[] = "%12s: % .4e %-12s\t";
|
||||
static const char newformat[] = "%12s: % .4e %-12s\n";
|
||||
|
||||
if ( values == NIL( GLOBvalues ) ) {
|
||||
fprintf( stderr, "Error: tried to print NIL GLOBvalues\n");
|
||||
|
|
|
|||
|
|
@ -277,8 +277,8 @@ MATLtempDep(MaterialInfo *info, double tnom)
|
|||
void
|
||||
printMaterialInfo(MaterialInfo *info)
|
||||
{
|
||||
static char *tabformat = "%12s: % .4e %-12s\t";
|
||||
static char *newformat = "%12s: % .4e %-12s\n";
|
||||
static const char tabformat[] = "%12s: % .4e %-12s\t";
|
||||
static const char newformat[] = "%12s: % .4e %-12s\n";
|
||||
|
||||
char *name;
|
||||
|
||||
|
|
|
|||
|
|
@ -344,8 +344,8 @@ struct MatrixElement
|
|||
void
|
||||
TWOmemStats(FILE *file, TWOdevice *pDevice)
|
||||
{
|
||||
static char *memFormat = "%-20s%10d%10d\n";
|
||||
/* static char *sumFormat = "%20s %-10d\n"; */
|
||||
static const char memFormat[] = "%-20s%10d%10d\n";
|
||||
/* static const char sumFormat[] = "%20s %-10d\n"; */
|
||||
unsigned int size;
|
||||
unsigned int memory;
|
||||
TWOmaterial *pMaterial;
|
||||
|
|
@ -432,7 +432,7 @@ TWOmemStats(FILE *file, TWOdevice *pDevice)
|
|||
void
|
||||
TWOcpuStats(FILE *file, TWOdevice *pDevice)
|
||||
{
|
||||
static char *cpuFormat = "%-20s%10g%10g%10g%10g%10g\n";
|
||||
static const char cpuFormat[] = "%-20s%10g%10g%10g%10g%10g\n";
|
||||
TWOstats *pStats = pDevice->pStats;
|
||||
double total;
|
||||
int iTotal;
|
||||
|
|
|
|||
Loading…
Reference in New Issue