Hello community,

here is the log from the commit of package perl-File-Tail for openSUSE:Factory 
checked in at 2015-08-03 17:22:30
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-File-Tail (Old)
 and      /work/SRC/openSUSE:Factory/.perl-File-Tail.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "perl-File-Tail"

Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-File-Tail/perl-File-Tail.changes    
2015-04-23 08:04:16.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-File-Tail.new/perl-File-Tail.changes       
2015-08-03 17:22:31.000000000 +0200
@@ -1,0 +2,14 @@
+Mon Aug  3 08:42:34 UTC 2015 - [email protected]
+
+- updated to 1.3
+   see /usr/share/doc/packages/perl-File-Tail/Changes
+
+  
+  1.3     Fix for a stupid bug in 1.2 (GFILATOV, Slaven_Rezic)
+          Added a warning for use of debug in a non-debug version of File::Tail
+          Shows a warning when maxbuf is set to a too-small value
+          Invoking name_changes callback changes the value of input attribute 
([email protected])
+          When deciding to reopen the file, check if the inode matches (that 
would mean it has not
+           been ranamed)
+
+-------------------------------------------------------------------

Old:
----
  File-Tail-1.2.tar.gz

New:
----
  File-Tail-1.3.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ perl-File-Tail.spec ++++++
--- /var/tmp/diff_new_pack.EF86U0/_old  2015-08-03 17:22:32.000000000 +0200
+++ /var/tmp/diff_new_pack.EF86U0/_new  2015-08-03 17:22:32.000000000 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           perl-File-Tail
-Version:        1.2
+Version:        1.3
 Release:        0
 %define cpan_name File-Tail
 Summary:        Perl extension for reading from continously updated files

++++++ File-Tail-1.2.tar.gz -> File-Tail-1.3.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/File-Tail-1.2/Changes new/File-Tail-1.3/Changes
--- old/File-Tail-1.2/Changes   2015-04-21 14:57:29.000000000 +0200
+++ new/File-Tail-1.3/Changes   2015-08-02 14:48:22.000000000 +0200
@@ -118,4 +118,12 @@
 
 1.2     Break the infinite loop that can result when the average length of 
lines
         causes the attempt to fill the tail buffer to fill with the exact same
-        or even smaller number of lines.
\ No newline at end of file
+        or even smaller number of lines.
+
+1.3     Fix for a stupid bug in 1.2 (GFILATOV, Slaven_Rezic)
+        Added a warning for use of debug in a non-debug version of File::Tail
+        Shows a warning when maxbuf is set to a too-small value
+        Invoking name_changes callback changes the value of input attribute 
([email protected])
+        When deciding to reopen the file, check if the inode matches (that 
would mean it has not
+         been ranamed)
+        
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/File-Tail-1.2/META.json new/File-Tail-1.3/META.json
--- old/File-Tail-1.2/META.json 2015-04-21 16:05:24.000000000 +0200
+++ new/File-Tail-1.3/META.json 2015-08-02 14:49:11.000000000 +0200
@@ -4,7 +4,7 @@
       "unknown"
    ],
    "dynamic_config" : 1,
-   "generated_by" : "ExtUtils::MakeMaker version 6.98, CPAN::Meta::Converter 
version 2.142690",
+   "generated_by" : "ExtUtils::MakeMaker version 6.98, CPAN::Meta::Converter 
version 2.150005",
    "license" : [
       "perl_5"
    ],
@@ -40,5 +40,6 @@
       }
    },
    "release_status" : "stable",
-   "version" : "1.2"
+   "version" : "1.3",
+   "x_serialization_backend" : "JSON::PP version 2.27203"
 }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/File-Tail-1.2/META.yml new/File-Tail-1.3/META.yml
--- old/File-Tail-1.2/META.yml  2015-04-21 16:05:24.000000000 +0200
+++ new/File-Tail-1.3/META.yml  2015-08-02 14:49:11.000000000 +0200
@@ -7,7 +7,7 @@
 configure_requires:
   ExtUtils::MakeMaker: '0'
 dynamic_config: 1
-generated_by: 'ExtUtils::MakeMaker version 6.98, CPAN::Meta::Converter version 
2.142690'
+generated_by: 'ExtUtils::MakeMaker version 6.98, CPAN::Meta::Converter version 
2.150005'
 license: perl
 meta-spec:
   url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -22,4 +22,5 @@
   FileHandle: '0'
   IO::Seekable: '0'
   Time::HiRes: '1.12'
-version: '1.2'
+version: '1.3'
+x_serialization_backend: 'CPAN::Meta::YAML version 0.016'
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/File-Tail-1.2/Tail.pm new/File-Tail-1.3/Tail.pm
--- old/File-Tail-1.2/Tail.pm   2015-04-21 16:05:24.000000000 +0200
+++ new/File-Tail-1.3/Tail.pm   2015-08-02 14:49:08.000000000 +0200
@@ -11,7 +11,7 @@
 # Items to export into callers namespace by default. Note: do not export
 # names by default without a very good reason. Use EXPORT_OK instead.
 # Do not simply export all your public functions/methods/constants.
-$VERSION = '1.2';
+$VERSION = '1.3';
 
 
 # Preloaded methods go here.
@@ -262,6 +262,8 @@
     $object->{"tail"}=($params{'tail'} || 0);
     $object->{"nowait"}=($params{'nowait'} || 0);
     $object->{"maxbuf"}=($params{'maxbuf'} || 16384);
+    warn "maxbuf should be big enough to hold at least one longest probable 
line, and preferably several\n"
+      unless $object->{"maxbuf"}>1024;
     $object->{"name_changes_callback"}=($params{'name_changes'} || undef);
     if (defined $params{'reset_tail'}) {
         $object->{"reset_tail"} = $params{'reset_tail'};
@@ -302,7 +304,7 @@
       my $avlen=length($object->{"buffer"})/($crs+1);
       $avlen=80 unless $avlen;
       my $calclen=$avlen*$object->{"tail"};
-      $calclen=length($object->{tail})+1024 if 
$calclen<=length($object->{"tail"});
+      $calclen=length($object->{buffer})+1024 if 
int($calclen)<=length($object->{"buffer"});
       $calclen=$maxlen if $calclen>$maxlen;
       $object->{curpos}=sysseek($object->{handle},-$calclen,SEEK_END);
       sysread($object->{handle},$object->{"buffer"},
@@ -349,6 +351,7 @@
     my $newname;
     if ($oldhandle && $$object{'name_changes_callback'}) {
        $newname=$$object{'name_changes_callback'}();
+        $object->{"input"}= $newname;
     } else {
        $newname=$object->input;
     }
@@ -371,7 +374,7 @@
        return;
     }
     binmode($newhandle);
-    
+
     if (defined($oldhandle)) {
        # If file has not been changed since last OK read do not do anything
        $st=stat($newhandle);
@@ -385,8 +388,8 @@
         # last read, and replaced (within that second) with a file of equal
         # length, we're out of luck. I don't see how to fix this.
        if ($st->mtime<=int($object->{'lastread'})) {
-           if ($st->size==$object->{"curpos"}) {
-               $object->{lastread} = $st->mtime; 
+           if (($st->size==$object->{"curpos"}) && ($st->ino == 
$object->{"inode"})) {
+               $object->{lastread} = $st->mtime;
                return;
            } else { 
                # will continue further to reset
@@ -394,6 +397,7 @@
        } else {
        }
        $object->{handle}=$newhandle;
+        $object->{inode} = $st->ino;
        $object->position;
        $object->{lastread} = $st->mtime;
        close($oldhandle);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/File-Tail-1.2/Tail.pm.debug 
new/File-Tail-1.3/Tail.pm.debug
--- old/File-Tail-1.2/Tail.pm.debug     2015-04-21 16:05:13.000000000 +0200
+++ new/File-Tail-1.3/Tail.pm.debug     2015-08-02 14:47:30.000000000 +0200
@@ -11,7 +11,7 @@
 # Items to export into callers namespace by default. Note: do not export
 # names by default without a very good reason. Use EXPORT_OK instead.
 # Do not simply export all your public functions/methods/constants.
-$VERSION = '1.2';
+$VERSION = '1.3';
 
 
 # Preloaded methods go here.
@@ -262,6 +262,8 @@
     $object->{"tail"}=($params{'tail'} || 0);
     $object->{"nowait"}=($params{'nowait'} || 0);
     $object->{"maxbuf"}=($params{'maxbuf'} || 16384);
+    warn "maxbuf should be big enough to hold at least one longest probable 
line, and preferably several\n"
+      unless $object->{"maxbuf"}>1024;
     $object->{"name_changes_callback"}=($params{'name_changes'} || undef);
     if (defined $params{'reset_tail'}) {
         $object->{"reset_tail"} = $params{'reset_tail'};
@@ -305,7 +307,7 @@
       my $avlen=length($object->{"buffer"})/($crs+1);
       $avlen=80 unless $avlen;
       my $calclen=$avlen*$object->{"tail"};
-      $calclen=length($object->{tail})+1024 if 
$calclen<=length($object->{"tail"});
+      $calclen=length($object->{buffer})+1024 if 
int($calclen)<=length($object->{"buffer"});
       $calclen=$maxlen if $calclen>$maxlen;
       $object->{curpos}=sysseek($object->{handle},-$calclen,SEEK_END);
       sysread($object->{handle},$object->{"buffer"},
@@ -353,6 +355,7 @@
     my $newname;
     if ($oldhandle && $$object{'name_changes_callback'}) {
        $newname=$$object{'name_changes_callback'}();
+        $object->{"input"}= $newname;
     } else {
        $newname=$object->input;
     }
@@ -375,7 +378,7 @@
        return;
     }
     binmode($newhandle);
-    
+
     if (defined($oldhandle)) {
        # If file has not been changed since last OK read do not do anything
        $st=stat($newhandle);
@@ -391,8 +394,8 @@
        if ($st->mtime<=int($object->{'lastread'})) {
            $object->logit(" File not modified since last read. Reset 
skipped.");
            $object->logit("mtime:",$st->mtime," lastread: 
",$object->{lastread});
-           if ($st->size==$object->{"curpos"}) {
-               $object->{lastread} = $st->mtime; 
+           if (($st->size==$object->{"curpos"}) && ($st->ino == 
$object->{"inode"})) {
+               $object->{lastread} = $st->mtime;
                return;
            } else { 
                $object->logit("Mtime is old (mtime:".$st->mtime." lastread 
".$object->{'lastread'}."), but size is not equal to position, therefore 
reset!");
@@ -404,6 +407,7 @@
        }
        $object->logit("reseting file mtime:",$st->mtime," lastread: 
",$object->{lastread}," size=",$st->size," read position=",$object->{"curpos"});
        $object->{handle}=$newhandle;
+        $object->{inode} = $st->ino;
        $object->position;
        $object->{lastread} = $st->mtime;
        close($oldhandle);


Reply via email to