Salome HOME
0021255: [CEA 466] compilation with gcc 4.6.0 without warnings
authoreap <eap@opencascade.com>
Tue, 3 May 2011 13:22:18 +0000 (13:22 +0000)
committereap <eap@opencascade.com>
Tue, 3 May 2011 13:22:18 +0000 (13:22 +0000)
-      rc = pthread_create(&threads[t], NULL, PrintHello, (void *)t) ;
+      rc = pthread_create(&threads[t], NULL, PrintHello, &t) ;

src/SALOMELocalTrace/Test/SALOMELocalTraceTest.cxx
src/SALOMETraceCollector/Test/SALOMETraceCollectorTest.cxx

index 1ea24f4c55aadbf926eb21e143fe2b108ac5a61f..b923174b6dbd40260967cdfa6633f8cc0d7cfe4f 100644 (file)
@@ -107,7 +107,7 @@ SALOMELocalTraceTest::testLoadBufferPoolLocal()
   for(t=0;t<numThread;t++)
     {
       MESSAGE("Creating thread " << t);
-      rc = pthread_create(&threads[t], NULL, PrintHello, (void *)t) ;
+      rc = pthread_create(&threads[t], NULL, PrintHello, &t) ;
       CPPUNIT_ASSERT( !rc);
     }
 
@@ -153,7 +153,7 @@ SALOMELocalTraceTest::testLoadBufferPoolFile()
   for(t=0;t<NUM_THREADS;t++)
     {
       MESSAGE("Creating thread " << t);
-      rc = pthread_create(&threads[t], NULL, PrintHello, (void *)t) ;
+      rc = pthread_create(&threads[t], NULL, PrintHello, &t) ;
       CPPUNIT_ASSERT( !rc);
     }
 
index bc7853097beb7e1fe4891322c91d9731d0fa9424..6919508edf7729c0f63307c0a4d2c95ce6112c1f 100644 (file)
@@ -75,7 +75,7 @@ SALOMETraceCollectorTest::testLoadBufferPoolCORBA()
   for(t=0;t<NUM_THREADS;t++)
     {
       MESSAGE("Creating thread " << t);
-      rc = pthread_create(&threads[t], NULL, PrintHello, (void *)t) ;
+      rc = pthread_create(&threads[t], NULL, PrintHello, &t) ;
       CPPUNIT_ASSERT( !rc);
     }