]> err.no Git - dpkg/commitdiff
Dpkg::Source::Archiver/Patch: Rename close() methods into finish()
authorRaphael Hertzog <hertzog@debian.org>
Fri, 22 Feb 2008 16:47:54 +0000 (17:47 +0100)
committerRaphael Hertzog <hertzog@debian.org>
Fri, 22 Feb 2008 16:47:54 +0000 (17:47 +0100)
* scripts/Dpkg/Source/Archiver.pm: Rename close() method into finish()
to avoid ambiguity with CORE::close().
* scripts/Dpkg/Source/Patch.pm: Same.
* scripts/dpkg-source.pl: Updated accordingly.

scripts/Dpkg/Source/Archiver.pm
scripts/Dpkg/Source/Patch.pm
scripts/dpkg-source.pl

index 5f761bf28ff68d44c82f1a1f3e68241dda898fa0..69fd1045d5b41d47a664921cd3b5e8daeb21717a 100644 (file)
@@ -67,7 +67,7 @@ sub add_directory {
     $self->_add_entry($file);
 }
 
-sub close {
+sub finish {
     my ($self) = @_;
     close($self->{'tar_input'}) or syserr(_g("close on tar input"));
     wait_child($self->{'pid'}, cmdline => 'tar -cf -');
index 6e7c2e6297cc86c05a66e95591ae3c8bb515fea8..14cd223fecc84026ef35c80b96a9fe7029d32587 100644 (file)
@@ -49,7 +49,7 @@ sub create {
         } else {
             $self->_fail_not_same_type($opts{'old'}, $opts{'new'});
         }
-        $self->close() unless $opts{"noclose"};
+        $self->finish() unless $opts{"nofinish"};
     }
 }
 
@@ -209,7 +209,7 @@ sub add_diff_directory {
     find({ wanted => $scan_old, no_chdir => 1 }, $old);
 }
 
-sub close {
+sub finish {
     my ($self) = @_;
     close($self->{'handle'}) ||
             syserr(_g("cannot close %s"), $self->get_filename());
index 005240f7319c476e06719a06ba4b4e06f55d846f..1a793d849a40ec0cb55da67ea8f25c703a3bb380 100755 (executable)
@@ -603,7 +603,7 @@ if ($opmode eq 'build') {
                    compression_level => $comp_level);
        $tar->create(options => \@tar_ignore);
        $tar->add_directory($tardirname);
-       $tar->close();
+       $tar->finish();
         rename($newtar, $tarname) ||
             syserr(_g("unable to rename `%s' (newly created) to `%s'"),
                    $newtar, $tarname);
@@ -657,7 +657,7 @@ if ($opmode eq 'build') {
         $diff->add_diff_directory($origdir, $dir,
                 basedirname => $basedirname,
                 diff_ignore_regexp => $diff_ignore_regexp);
-        $diff->close() || $ur++;
+        $diff->finish() || $ur++;
 
        rename($newdiffgz, $diffname) ||
            syserr(_g("unable to rename `%s' (newly created) to `%s'"),