]> git.pld-linux.org Git - packages/extundelete.git/commitdiff
Update to 0.2.4 auto/th/extundelete-0.2.4-1
authorMarcin Banasiak <marcin.banasiak@gmail.com>
Thu, 25 Dec 2014 00:33:09 +0000 (01:33 +0100)
committerMarcin Banasiak <marcin.banasiak@gmail.com>
Thu, 25 Dec 2014 00:33:09 +0000 (01:33 +0100)
- updated -attrs.patch and -dirs.patch

extundelete-attrs.patch
extundelete-dirs.patch
extundelete.spec

index db21f954dd83c64f8b8e694a6d670c9714097afa..3a9bd380745790cb9638f6df2b5d286925b19935 100644 (file)
@@ -1,5 +1,5 @@
---- a/src/extundelete.cc       2010-05-16 03:51:15.000000000 +0200
-+++ b/src/extundelete.cc       2012-01-01 15:54:07.000000000 +0100
+--- extundelete-0.2.4/src/extundelete.cc.orig  2014-12-24 14:00:40.401233636 +0100
++++ extundelete-0.2.4/src/extundelete.cc       2014-12-24 14:41:00.240755859 +0100
 @@ -89,6 +89,7 @@ Important future enhancements:
  #include <fcntl.h>
  #include <unistd.h>
@@ -8,19 +8,19 @@
  
  /* GNU headers */
  #ifndef HAVE_GETOPT_H
-@@ -2532,8 +2533,14 @@ int restore_inode(ext2_filsys fs, ext2_f
-                       if(!flag) {
-                               if (truncate( (outputdir + fname2).c_str(), EXT2_I_SIZE(inode)) == 0) {
+@@ -1746,8 +1746,14 @@ errcode_t restore_inode(ext2_filsys fs,
+                               }
+                               tsize = fsize - rsize;
+                               if ((retval = truncate( (outputdir + fname2).c_str(), tsize)) == 0) {
 +                                      struct timeval times[2];
 +                                      chmod((outputdir + fname2).c_str(),inode->i_mode);
 +                                      lchown((outputdir + fname2).c_str(),inode->i_uid,inode->i_gid);
 +                                      times[0].tv_sec=inode->i_atime; times[0].tv_usec=0;
 +                                      times[1].tv_sec=inode->i_mtime; times[1].tv_usec=0;
 +                                      utimes((outputdir + fname2).c_str(),times);
-                                       std::cout << "Restored inode " << ino << " to file ";
--                                      std::cout << (outputdir + fname2) << std::endl;
-+                                      std::cout << (outputdir + fname2) << " deleted " << asctime(localtime((time_t*)&inode->i_dtime));
+                                       Log::info << "Restored inode " << ino << " to file "
+-                                      << (outputdir + fname2) << std::endl;
++                                      << (outputdir + fname2) << " deleted " << asctime(localtime((time_t*)&inode->i_dtime)) << std::endl;
                                        retval = 0;
                                } else {
-                                       std::cout << "Failed to restore inode " << ino << " to file ";
+                                       Log::warn << "Failed to restore inode " << ino << " to file "
index 0dfa78579369c4f393fae868b10403c8eca0fe99..1233a3526acc4a126f410614fff2f3634b203b05 100644 (file)
@@ -1,27 +1,26 @@
-diff -urNp a/src/extundelete.cc b/src/extundelete.cc
---- a/src/extundelete.cc       2010-05-16 03:51:15.000000000 +0200
-+++ b/src/extundelete.cc       2012-01-01 22:51:46.000000000 +0100
-@@ -2556,6 +2556,23 @@ int restore_inode(ext2_filsys fs, ext2_f
+--- extundelete-0.2.4/src/extundelete.cc.orig  2014-12-24 14:00:40.401233636 +0100
++++ extundelete-0.2.4/src/extundelete.cc       2014-12-25 01:29:09.076514586 +0100
+@@ -1777,6 +1777,23 @@ errcode_t restore_inode(ext2_filsys fs,
                        retval = EU_RESTORE_FAIL;
                }
        }
 +      else if (LINUX_S_ISDIR(inode->i_mode)) {
-+              if(mkdir((outputdir2 + fname2).c_str(), 0700)) {
-+                      struct timeval times[2];
-+                      chmod((outputdir + fname2).c_str(),inode->i_mode);
-+                      lchown((outputdir + fname2).c_str(),inode->i_uid,inode->i_gid);
-+                      times[0].tv_sec=inode->i_atime; times[0].tv_usec=0;
-+                      times[1].tv_sec=inode->i_mtime; times[1].tv_usec=0;
-+                      utimes((outputdir + fname2).c_str(),times);
-+                      std::cout << "Restored inode " << ino << " as directory ";
-+                      std::cout << (outputdir + fname2) << " deleted " << asctime(localtime((time_t*)&inode->i_dtime));
-+                      retval = 0;
-+              } else {
-+                      std::cout << "Failed to restore inode " << ino << " as directory ";
-+                      std::cout << (outputdir + fname2) << " deleted " << asctime(localtime((time_t*)&inode->i_dtime));
-+                      retval = EU_RESTORE_FAIL;
-+              }
++              if(mkdir((outputdir2 + fname2).c_str(), 0700)) {
++                      struct timeval times[2];
++                      chmod((outputdir + fname2).c_str(),inode->i_mode);
++                      lchown((outputdir + fname2).c_str(),inode->i_uid,inode->i_gid);
++                      times[0].tv_sec=inode->i_atime; times[0].tv_usec=0;
++                      times[1].tv_sec=inode->i_mtime; times[1].tv_usec=0;
++                      utimes((outputdir + fname2).c_str(),times);
++                      std::cout << "Restored inode " << ino << " as directory ";
++                      std::cout << (outputdir + fname2) << " deleted " << asctime(localtime((time_t*)&inode->i_dtime));
++                      retval = 0;
++              } else {
++                      std::cout << "Failed to restore inode " << ino << " as directory ";
++                      std::cout << (outputdir + fname2) << " deleted " << asctime(localtime((time_t*)&inode->i_dtime));
++                      retval = EU_RESTORE_FAIL;
++              }
 +      }
        else {
-               std::cout << "Failed to restore inode " << ino << " to file ";
-               std::cout << (outputdir + fname2) << ":";
+               Log::info << "extundelete identified inode " << ino << " as "
+               << (outputdir + fname2) << ":"
index 4a88a90c7e72d0d5804d5e42b069faccfc12f08f..b5103ec4f5620b09e4375a555bb84cd515e8125c 100644 (file)
@@ -1,11 +1,11 @@
 Summary:       Recover deleted files from an ext3 or ext4 partition
 Name:          extundelete
-Version:       0.2.0
-Release:       2
+Version:       0.2.4
+Release:       1
 License:       GPL v2
 Group:         Applications/System
-Source0:       http://dl.sourceforge.net/extundelete/%{name}-%{version}.tar.bz2
-# Source0-md5: 6dac74b12a747f133326ff7b81fceedd
+Source0:       http://download.sourceforge.net/extundelete/%{name}-%{version}.tar.bz2
+# Source0-md5: 77e626ad31433680c0a222069295d2ca
 URL:           http://extundelete.sourceforge.net/
 Patch0:                %{name}-attrs.patch
 Patch1:                %{name}-dirs.patch
This page took 0.090317 seconds and 4 git commands to generate.