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

Maximiliano Curia maxy at moszumanska.debian.org
Thu Jul 13 17:47:09 UTC 2017


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

The following commit has been merged in the master branch:
commit bea89ba81ac03c644480fdd2b0b0821392bef530
Author: Robin Mills <robin at clanmills.com>
Date:   Tue Oct 4 15:16:56 2016 +0000

    #1230.  Rollback 4604.  I knew webp-test was sometimes failing.  Fixed. Always use runTest exiv2 to be sure of executing the hot build of exiv2(.exe).
---
 src/exiv2.cpp     | 29 ++++++-------------------
 src/exiv2app.hpp  |  9 +-------
 test/webp-test.sh | 65 +++++++++++++++++++++++++++----------------------------
 3 files changed, 40 insertions(+), 63 deletions(-)

diff --git a/src/exiv2.cpp b/src/exiv2.cpp
index 23563f9..1158b36 100644
--- a/src/exiv2.cpp
+++ b/src/exiv2.cpp
@@ -138,9 +138,6 @@ int main(int argc, char* const argv[])
 
     // Handle command line arguments
     Params& params = Params::instance();
-    params.argc_=argc;
-    params.argv_=argv;
-
     if (params.getopt(argc, argv)) {
         params.usage();
         return 1;
@@ -606,9 +603,8 @@ int Params::evalPrint(const std::string& optarg)
         case 'S': action_ = Action::print; printMode_ = pmStructure  ; break;
         case 'X': action_ = Action::print; printMode_ = pmXMP        ; break;
         default:
-            std::cerr << progname() << ": " << _("Unrecognized print mode ")
-                     << "'"<< optarg<<"'"  << std::endl;
-            verboseDump();
+            std::cerr << progname() << ": " << _("Unrecognized print mode") << " `"
+                      << optarg << "'
";
             rc = 1;
             break;
         }
@@ -881,17 +877,6 @@ int Params::nonoption(const std::string& argv)
     return rc;
 } // Params::nonoption
 
-void Params::verboseDump()
-{
-    //if ( verbose_ ) {
-        std::cerr << "argc = " << argc_ << std::endl;
-        if ( argv_ )
-            for ( int a = 0 ; a < argc_ ; a++)
-                std::cerr << "argv[" <<a<< "] =" << argv_[a] << std::endl;
-    //    Exiv2::dumpLibraryInfo(std::cerr,greps_);
-    //}
-}
-
 static int readFileToBuf(FILE* f,Exiv2::DataBuf& buf)
 {
     const int buff_size = 4*1028;
@@ -921,7 +906,7 @@ static int readFileToBuf(FILE* f,Exiv2::DataBuf& buf)
 void Params::getStdin(Exiv2::DataBuf& buf)
 {
     // copy stdin to stdinBuf
-    if ( stdinBuf_.size_ == 0 ) {
+    if ( stdinBuf.size_ == 0 ) {
 #if defined(_WIN32) || defined(__CYGWIN__) || defined(__MINGW__) || defined(_MSC_VER)
         DWORD fdwMode;
         _setmode(fileno(stdin), O_BINARY);
@@ -940,7 +925,7 @@ void Params::getStdin(Exiv2::DataBuf& buf)
 #ifdef DEBUG
             std::cerr << "stdin has data" << std::endl;
 #endif
-            readFileToBuf(stdin,stdinBuf_);
+            readFileToBuf(stdin,stdinBuf);
         }
 #ifdef DEBUG
         // this is only used to simulate reading from stdin when debugging
@@ -962,9 +947,9 @@ void Params::getStdin(Exiv2::DataBuf& buf)
     }
 
     // copy stdinBuf to buf
-    if ( stdinBuf_.size_ ) {
-        buf.alloc(stdinBuf_.size_);
-        memcpy(buf.pData_,stdinBuf_.pData_,buf.size_);
+    if ( stdinBuf.size_ ) {
+        buf.alloc(stdinBuf.size_);
+        memcpy(buf.pData_,stdinBuf.pData_,buf.size_);
     }
 #ifdef DEBUG
     std::cerr << "getStdin stdinBuf.size_ = " << stdinBuf.size_ << std::endl;
diff --git a/src/exiv2app.hpp b/src/exiv2app.hpp
index 379f4e1..d3b5957 100644
--- a/src/exiv2app.hpp
+++ b/src/exiv2app.hpp
@@ -256,9 +256,7 @@ public:
     Keys  keys_;                        //!< List of keys to match from the metadata
     std::string charset_;               //!< Charset to use for UNICODE Exif user comment
 
-    Exiv2::DataBuf  stdinBuf_;         //! < DataBuf with the binary bytes from stdin
-    int             argc_;             //! < command-line arg count
-    char* const*    argv_;             //! < command-line arg vector
+    Exiv2::DataBuf  stdinBuf;           //! < DataBuf with the binary bytes from stdin
 
 private:
     //! Pointer to the global Params object.
@@ -295,8 +293,6 @@ private:
                formatSet_(false),
                first_(true)
     {
-        argc_=0;
-        argv_=NULL;
         yodAdjust_[yodYear]  = emptyYodAdjust_[yodYear];
         yodAdjust_[yodMonth] = emptyYodAdjust_[yodMonth];
         yodAdjust_[yodDay]   = emptyYodAdjust_[yodDay];
@@ -359,9 +355,6 @@ public:
     */
     void getStdin(Exiv2::DataBuf& buf);
 
-    //! verboseDump is used to debug the command line
-    void verboseDump();
-
 }; // class Params
 
 #endif                                  // #ifndef EXIV2APP_HPP_
diff --git a/test/webp-test.sh b/test/webp-test.sh
index 54174c3..04ffe19 100755
--- a/test/webp-test.sh
+++ b/test/webp-test.sh
@@ -7,78 +7,77 @@ source ./functions.source
 
     num=1199                    # WebPImage
     printf "WebP " >&3
-#    verbose=--verbose
     filename=exiv2-bug$num.webp # http://dev.exiv2.org/attachments/download/1033/Stonehenge-with-icc.webp
     icc_name=exiv2-bug$num.icc
     exv_name=exiv2-bug$num.exv
     xmp_name=exiv2-bug$num.xmp
 
     copyTestFile                        $filename
-    runTest exiv2 $verbose -pS          $filename
-    runTest exiv2 $verbose -pR          $filename
-    runTest exiv2 $verbose -pX          $filename | xmllint --format -
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -pR                   $filename
+    runTest exiv2 -pX                   $filename | xmllint --format -
     printf "delete " >&3
     # test deleting metadata
     for option in -dC -de -dx -dCe -dCx -dCxe; do
       copyTestFile                      $filename
-      runTest exiv2 $verbose -pS        $filename
+      runTest exiv2 -pS                 $filename
       runTest exiv2 $option             $filename
-      runTest exiv2 $verbose -pS        $filename
+      runTest exiv2 -pS                 $filename
     done
 
     printf "insert " >&3
     printf "ICC "    >&3
     copyTestFile                        $filename
-    exiv2 $verbose -pS                  $filename
+    runTest exiv2 -pS                   $filename
     copyTestFile                        Reagan.tiff
-    exiv2 $verbose -pC                  Reagan.tiff > $icc_name
-    exiv2 $verbose -iC                  $filename
-    exiv2 -pS                           $filename
+    runTest exiv2 -pC                   Reagan.tiff > $icc_name
+    runTest exiv2 -iC                   $filename
+    runTest exiv2 -pS                   $filename
 
     printf "XMP " >&3
     # copy the XMP from the test file
     copyTestFile                        $filename
-    exiv2 $verbose -pX                  $filename   > $xmp_name;
-    exiv2 $verbose -ea --force          $filename
+    runTest exiv2 -pX                   $filename   > $xmp_name;
+    runTest exiv2 -ea --force           $filename
 
     copyTestFile                        $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -iXX                 $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -ix                  $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -iXX                  $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -ix                   $filename
 
     # copy the XMP from Reagan.tiff to test file
     copyTestFile                        Reagan.tiff
-    exiv2 $verbose -pX                  Reagan.tiff > $xmp_name;
-    exiv2 $verbose -ea --force          Reagan.tiff
+    runTest exiv2 -pX                   Reagan.tiff > $xmp_name;
+    runTest exiv2 -ea --force           Reagan.tiff
     mv                                  Reagan.exv    $exv_name
 
     copyTestFile                        $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -iXX                 $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -ix                  $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -iXX                  $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -ix                   $filename
 
     # copy the XMP from exiv2-bug922.jpg to test file
     copyTestFile                        exiv2-bug922.jpg
-    exiv2 $verbose -pX                  exiv2-bug922.jpg > $xmp_name
-    exiv2 $verbose -ea --force          exiv2-bug922.jpg 2>/dev/null
+    runTest exiv2 -pX                   exiv2-bug922.jpg > $xmp_name
+    runTest exiv2 -ea --force           exiv2-bug922.jpg 2>/dev/null
     mv                                  exiv2-bug922.exv   $exv_name
 
     copyTestFile                        $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -ix                  $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -iXX                 $filename
-    exiv2 $verbose -pS                  $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -ix                   $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -iXX                  $filename
+    runTest exiv2 -pS                   $filename
 
     printf "EXIF " >&3
     copyTestFile                        exiv2-bug922.jpg $filename
-    exiv2 $verbose --force -ea          $filename
+    runTest exiv2 --force -ea           $filename
     copyTestFile                        $filename
-    exiv2 $verbose -pS                  $filename
-    exiv2 $verbose -ie                  $filename
-    exiv2 $verbose -pS                  $filename
+    runTest exiv2 -pS                   $filename
+    runTest exiv2 -ie                   $filename
+    runTest exiv2 -pS                   $filename
 
 ) 3>&1 > $results 2>&1
 

-- 
exiv2 packaging



More information about the pkg-kde-commits mailing list