X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=libs%2Finterprocess%2Ftest%2Fintersegment_ptr_test.cpp;h=cacdbbd37302bff9cc1b44c9aa486035a148f5a2;hb=08c1e93fa36a49f49325a07fe91ff92c964c2b6c;hp=709acd4dc63984a01c48616559e84825f50d1578;hpb=bb4dd8289b351fae6b55e303f189127a394a1edd;p=platform%2Fupstream%2Fboost.git diff --git a/libs/interprocess/test/intersegment_ptr_test.cpp b/libs/interprocess/test/intersegment_ptr_test.cpp index 709acd4..cacdbbd 100644 --- a/libs/interprocess/test/intersegment_ptr_test.cpp +++ b/libs/interprocess/test/intersegment_ptr_test.cpp @@ -1,6 +1,6 @@ ////////////////////////////////////////////////////////////////////////////// // -// (C) Copyright Ion Gaztanaga 2007. Distributed under the Boost +// (C) Copyright Ion Gaztanaga 2007-2012. Distributed under the Boost // Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) // @@ -48,7 +48,7 @@ bool test_types_and_convertions() pcint_t pcint(0); pvint_t pvint(0); pcvint_t pcvint(0); - + pint = &dummy_int; pcint = &dummy_int; pvint = &dummy_int; @@ -75,7 +75,7 @@ bool test_arithmetic() typedef intersegment_ptr pint_t; const int NumValues = 5; int values[NumValues]; - + //Initialize p pint_t p = values; if(p.get() != values) @@ -130,15 +130,15 @@ bool test_arithmetic() //ptr++ penew = p0; for(int j = 0; j != NumValues; ++j){ - pint_t p = penew; - if(p != penew++) + pint_t pnew_copy = penew; + if(pnew_copy != penew++) return false; } //ptr-- p0 = pe; for(int j = 0; j != NumValues; ++j){ - pint_t p = p0; - if(p != p0--) + pint_t p0_copy = p0; + if(p0_copy != p0--) return false; } @@ -376,7 +376,7 @@ bool test_multi_segment_shared_memory() shared_memory_object::remove("kk0"); managed_multi_shared_memory mshm(create_only, "kk", 4096); } - + shared_memory_object::remove("kk0"); return true; }