Browse Source

[2381] Change more occurences of 0 to NULL

Mukund Sivaraman 12 years ago
parent
commit
caa37a99fc

+ 1 - 1
src/lib/util/tests/memory_segment_common_unittest.cc

@@ -64,7 +64,7 @@ checkSegmentNamedAddress(MemorySegment& segment, bool out_of_segment_ok) {
     EXPECT_FALSE(segment.clearNamedAddress("test address"));
     EXPECT_FALSE(segment.clearNamedAddress("test address"));
 
 
     // Setting NULL is okay.
     // Setting NULL is okay.
-    EXPECT_FALSE(segment.setNamedAddress("null address", 0));
+    EXPECT_FALSE(segment.setNamedAddress("null address", NULL));
     EXPECT_EQ(static_cast<void*>(NULL),
     EXPECT_EQ(static_cast<void*>(NULL),
               segment.getNamedAddress("null address"));
               segment.getNamedAddress("null address"));
 
 

+ 1 - 1
src/lib/util/tests/memory_segment_mapped_unittest.cc

@@ -89,7 +89,7 @@ TEST_F(MemorySegmentMappedTest, createAndModify) {
         EXPECT_TRUE(segment_->allMemoryDeallocated());
         EXPECT_TRUE(segment_->allMemoryDeallocated());
 
 
         void* ptr = segment_->allocate(1024);
         void* ptr = segment_->allocate(1024);
-        EXPECT_NE(static_cast<void*>(0), ptr);
+        EXPECT_NE(static_cast<void*>(NULL), ptr);
 
 
         // Now, we have an allocation:
         // Now, we have an allocation:
         EXPECT_FALSE(segment_->allMemoryDeallocated());
         EXPECT_FALSE(segment_->allMemoryDeallocated());