Parcourir la source

[2100] remove 'unused' table variable

my compiler even checks assignment-only variables, apparently
Jelte Jansen il y a 12 ans
Parent
commit
da5c0338f5
1 fichiers modifiés avec 1 ajouts et 2 suppressions
  1. 1 2
      src/lib/datasrc/memory/tests/zone_table_unittest.cc

+ 1 - 2
src/lib/datasrc/memory/tests/zone_table_unittest.cc

@@ -80,8 +80,7 @@ TEST_F(ZoneTableTest, create) {
     // tests.  We only check exception safety by letting the test memory
     // segment throw.
     mem_sgmt_.setThrowCount(2);
-    ZoneTable* table;
-    EXPECT_THROW(table = ZoneTable::create(mem_sgmt_), std::bad_alloc);
+    EXPECT_THROW(ZoneTable::create(mem_sgmt_), std::bad_alloc);
     // This shouldn't cause memory leak (that would be caught in TearDown()).
 }