changeset 2731:fe4fe52f0c94

fix warnings
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 13 Jul 2018 12:35:31 +0200
parents cb1b26a7db98
children 5af6e29c195f 8719a94bc731
files OrthancServer/ServerJobs/ArchiveJob.h UnitTestsSources/MultiThreadingTests.cpp
diffstat 2 files changed, 6 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/OrthancServer/ServerJobs/ArchiveJob.h	Fri Jul 13 12:34:53 2018 +0200
+++ b/OrthancServer/ServerJobs/ArchiveJob.h	Fri Jul 13 12:35:31 2018 +0200
@@ -49,7 +49,6 @@
     class ResourceIdentifiers;
     class ZipCommands;
     class ZipWriterIterator;
-    class ZipWriterIterator;
     
     boost::shared_ptr<TemporaryFile>      target_;
     ServerContext&                        context_;
--- a/UnitTestsSources/MultiThreadingTests.cpp	Fri Jul 13 12:34:53 2018 +0200
+++ b/UnitTestsSources/MultiThreadingTests.cpp	Fri Jul 13 12:35:31 2018 +0200
@@ -942,8 +942,9 @@
     operation.reset(unserializer.UnserializeOperation(s));
 
     // Make sure that we have indeed unserialized a log operation
-    ASSERT_THROW(dynamic_cast<DeleteResourceOperation&>(*operation), std::bad_cast);
-    dynamic_cast<LogJobOperation&>(*operation);
+    Json::Value dummy;
+    ASSERT_THROW(dynamic_cast<DeleteResourceOperation&>(*operation).Serialize(dummy), std::bad_cast);
+    dynamic_cast<LogJobOperation&>(*operation).Serialize(dummy);
   }
 }
 
@@ -1288,8 +1289,9 @@
   {
     operation.reset(unserializer.UnserializeOperation(s));
 
-    ASSERT_THROW(dynamic_cast<LogJobOperation&>(*operation), std::bad_cast);
-    dynamic_cast<DeleteResourceOperation&>(*operation);
+    Json::Value dummy;
+    ASSERT_THROW(dynamic_cast<LogJobOperation&>(*operation).Serialize(dummy), std::bad_cast);
+    dynamic_cast<DeleteResourceOperation&>(*operation).Serialize(dummy);
   }
 
   // StorePeerOperation