[SCM] exiv2 packaging branch, master, updated. debian/0.25-3.1-3734-gdcbc29a

Maximiliano Curia maxy at moszumanska.debian.org
Thu Jul 13 17:36:26 UTC 2017


Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=bb7a34b

The following commit has been merged in the master branch:
commit bb7a34bc1ed3fd8232450158b7f43e0f26298169
Author: Andreas Huggel <ahuggel at gmx.net>
Date:   Wed Jun 2 05:37:27 2004 +0000

    Fixed MSVC errors and warnings (Steve, sking_2_mod_2.patch)
---
 src/image.cpp | 19 ++++++++++++++-----
 src/types.hpp | 11 ++++++++++-
 2 files changed, 24 insertions(+), 6 deletions(-)

diff --git a/src/image.cpp b/src/image.cpp
index 3224cc3..da0788f 100644
--- a/src/image.cpp
+++ b/src/image.cpp
@@ -20,14 +20,14 @@
  */
 /*
   File:      image.cpp
-  Version:   $Name:  $ $Revision: 1.15 $
+  Version:   $Name:  $ $Revision: 1.16 $
   Author(s): Andreas Huggel (ahu) <ahuggel at gmx.net>
   History:   26-Jan-04, ahu: created
              11-Feb-04, ahu: isolated as a component
  */
 // *****************************************************************************
 #include "rcsid.hpp"
-EXIV2_RCSID("@(#) $Name:  $ $Revision: 1.15 $ $RCSfile: image.cpp,v $")
+EXIV2_RCSID("@(#) $Name:  $ $Revision: 1.16 $ $RCSfile: image.cpp,v $")
 
 // *****************************************************************************
 // included header files
@@ -38,7 +38,14 @@ EXIV2_RCSID("@(#) $Name:  $ $Revision: 1.15 $ $RCSfile: image.cpp,v $")
 #include <iostream>
 #include <fstream>
 #include <cstring>
-#include <cstdio>                               // for rename, remove, tmpnam
+#include <cstdio>                               // for rename, remove
+#ifdef _MSC_VER
+#include <process.h>
+typedef int pid_t;
+#else
+#include <sys/types.h>                          // for getpid
+#include <unistd.h>                             // for getpid
+#endif
 
 // *****************************************************************************
 // class member definitions
@@ -192,7 +199,8 @@ namespace Exiv2 {
         if (!is) return -1;
 
         // Write the output to a temporary file
-        std::string tmpname = tmpnam(NULL);
+        pid_t pid = getpid();
+        std::string tmpname = path + toString(pid);
         std::ofstream os(tmpname.c_str(), std::ios::binary);
         if (!os) return -3;
 
@@ -289,7 +297,8 @@ namespace Exiv2 {
         if (!is) return -1;
 
         // Write the output to a temporary file
-        std::string tmpname = tmpnam(NULL);
+        pid_t pid = getpid();
+        std::string tmpname = path + toString(pid);
         std::ofstream os(tmpname.c_str(), std::ios::binary);
         if (!os) return -3;
 
diff --git a/src/types.hpp b/src/types.hpp
index e56a7c3..5461165 100644
--- a/src/types.hpp
+++ b/src/types.hpp
@@ -21,7 +21,7 @@
 /*!
   @file    types.hpp
   @brief   Type definitions for %Exiv2 and related functionality
-  @version $Name:  $ $Revision: 1.13 $
+  @version $Name:  $ $Revision: 1.14 $
   @author  Andreas Huggel (ahu)
            <a href="mailto:ahuggel at gmx.net">ahuggel at gmx.net</a>
   @date    09-Jan-04, ahu: created
@@ -39,6 +39,13 @@
 #include <utility>
 #include <sstream>
 
+
+#ifdef _MSC_VER
+// disable unreferenced formal parameter warning C4100
+// disable truncation of constant value warning C4309
+#pragma warning (disable: 4100 4309)
+#endif
+
 // *****************************************************************************
 // namespace extensions
 namespace Exiv2 {
@@ -55,6 +62,8 @@ namespace Exiv2 {
     //! 4 byte signed integer type.
     typedef long           int32;
 
+
+
     //! 8 byte unsigned rational type.
     typedef std::pair<uint32, uint32> URational;
     //! 8 byte signed rational type.

-- 
exiv2 packaging



More information about the pkg-kde-commits mailing list