1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0023098: Cppcheck warnings/errors in QA files

Fix for cppcheck warnings
Warning fixes
This commit is contained in:
dbv
2012-10-12 14:23:00 +04:00
parent a7ae5c810a
commit f1e162f2ad
7 changed files with 106 additions and 119 deletions

View File

@@ -481,12 +481,12 @@ static Standard_Integer QAAISGetPixelColor (Draw_Interpretor& di, Standard_Integ
Standard_Integer QAAISXWindowSize_X = 0;
Standard_Integer QAAISXWindowSize_Y = 0;
QAAISWindow->Size(QAAISXWindowSize_X, QAAISXWindowSize_Y);
Standard_ShortReal QAAISCoordinateX = atof (argv [1]);
Standard_ShortReal QAAISCoordinateY = atof (argv [2]);
Standard_Integer QAAISCoordinateX = atoi (argv [1]);
Standard_Integer QAAISCoordinateY = atoi (argv [2]);
Standard_ShortReal QAAISColorRED_V = 0;
Standard_ShortReal QAAISColorGRN_V = 0;
Standard_ShortReal QAAISColorBLU_V = 0;
Standard_Real QAAISColorRED_V = 0;
Standard_Real QAAISColorGRN_V = 0;
Standard_Real QAAISColorBLU_V = 0;
if ( argc == 6 ) {
QAAISColorRED_V = atof (argv [3]);
@@ -512,9 +512,9 @@ static Standard_Integer QAAISGetPixelColor (Draw_Interpretor& di, Standard_Integ
Standard_Integer i;
for(i=1; i<=aSeq->Length();i+=3) {
// mkv 29.04.03
Standard_ShortReal QAAISColorRED_R = (((Standard_ShortReal) ((Standard_Integer) (aSeq->Value(i+0) * 1000000))) / 1000000.);
Standard_ShortReal QAAISColorGRN_R = (((Standard_ShortReal) ((Standard_Integer) (aSeq->Value(i+1) * 1000000))) / 1000000.);
Standard_ShortReal QAAISColorBLU_R = (((Standard_ShortReal) ((Standard_Integer) (aSeq->Value(i+2) * 1000000))) / 1000000.);
Standard_Real QAAISColorRED_R = (Floor(aSeq->Value(i+0) * 1000000.)) / 1000000.;
Standard_Real QAAISColorGRN_R = (Floor(aSeq->Value(i+1) * 1000000.)) / 1000000.;
Standard_Real QAAISColorBLU_R = (Floor(aSeq->Value(i+2) * 1000000.)) / 1000000.;
// mkv 29.04.03
if ( argc == 3 ) {