changeset 3402:cf31b5bacce3

removing unneeded casts
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 07 Jun 2019 15:06:17 +0200
parents 962e5f00744b
children 630fc934597f
files Core/DicomNetworking/DicomUserConnection.cpp Core/HttpServer/StringHttpOutput.cpp Core/Images/PngWriter.cpp Core/SystemToolbox.cpp
diffstat 4 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/Core/DicomNetworking/DicomUserConnection.cpp	Fri Jun 07 14:58:27 2019 +0200
+++ b/Core/DicomNetworking/DicomUserConnection.cpp	Fri Jun 07 15:06:17 2019 +0200
@@ -1123,7 +1123,7 @@
                                   uint16_t moveOriginatorID)
   {
     if (buffer.size() > 0)
-      Store(reinterpret_cast<const char*>(&buffer[0]), buffer.size(), moveOriginatorAET, moveOriginatorID);
+      Store(&buffer[0], buffer.size(), moveOriginatorAET, moveOriginatorID);
     else
       Store(NULL, 0, moveOriginatorAET, moveOriginatorID);
   }
--- a/Core/HttpServer/StringHttpOutput.cpp	Fri Jun 07 14:58:27 2019 +0200
+++ b/Core/HttpServer/StringHttpOutput.cpp	Fri Jun 07 15:06:17 2019 +0200
@@ -59,7 +59,7 @@
   {
     if (!isHeader)
     {
-      buffer_.AddChunk(reinterpret_cast<const char*>(buffer), length);
+      buffer_.AddChunk(buffer, length);
     }
   }
 
--- a/Core/Images/PngWriter.cpp	Fri Jun 07 14:58:27 2019 +0200
+++ b/Core/Images/PngWriter.cpp	Fri Jun 07 15:06:17 2019 +0200
@@ -243,7 +243,7 @@
                              png_size_t size)
   {
     ChunkedBuffer* buffer = reinterpret_cast<ChunkedBuffer*>(png_get_io_ptr(png_ptr));
-    buffer->AddChunk(reinterpret_cast<const char*>(data), size);
+    buffer->AddChunk(data, size);
   }
 
 
--- a/Core/SystemToolbox.cpp	Fri Jun 07 14:58:27 2019 +0200
+++ b/Core/SystemToolbox.cpp	Fri Jun 07 15:06:17 2019 +0200
@@ -231,7 +231,7 @@
     content.resize(static_cast<size_t>(size));
     if (size != 0)
     {
-      f.read(reinterpret_cast<char*>(&content[0]), size);
+      f.read(&content[0], size);
     }
 
     f.close();
@@ -274,7 +274,7 @@
     header.resize(headerSize);
     if (headerSize != 0)
     {
-      f.read(reinterpret_cast<char*>(&header[0]), headerSize);
+      f.read(&header[0], headerSize);
     }
 
     f.close();