don't pass state, we get them from the progressmeter
authorespie <espie@openbsd.org>
Tue, 23 May 2023 10:02:46 +0000 (10:02 +0000)
committerespie <espie@openbsd.org>
Tue, 23 May 2023 10:02:46 +0000 (10:02 +0000)
usr.sbin/pkg_add/OpenBSD/Add.pm
usr.sbin/pkg_add/OpenBSD/PkgCreate.pm

index 88b1582..d0948a9 100644 (file)
@@ -1,5 +1,5 @@
 # ex:ts=8 sw=4:
-# $OpenBSD: Add.pm,v 1.192 2022/05/11 09:47:23 espie Exp $
+# $OpenBSD: Add.pm,v 1.193 2023/05/23 10:02:46 espie Exp $
 #
 # Copyright (c) 2003-2014 Marc Espie <espie@openbsd.org>
 #
@@ -146,7 +146,7 @@ sub perform_extraction
        # For "tied" entries, also see tie_files in OpenBSD::PkgAdd.
        my ($wanted, $tied) = ({}, {});
        $handle->{plist}->find_extractible($state, $wanted, $tied);
-       my $p = $state->progress->new_sizer($handle->{plist}, $state);
+       my $p = $state->progress->new_sizer($handle->{plist});
 
        # so iterate over the archive, and "consume" hashes entry as we go
        # it's necessary to delete them so that skip_to_the_end will work
index 9d66d56..2b586a0 100644 (file)
@@ -1,6 +1,6 @@
 #! /usr/bin/perl
 # ex:ts=8 sw=4:
-# $OpenBSD: PkgCreate.pm,v 1.189 2023/05/22 12:05:57 espie Exp $
+# $OpenBSD: PkgCreate.pm,v 1.190 2023/05/23 10:02:46 espie Exp $
 #
 # Copyright (c) 2003-2014 Marc Espie <espie@openbsd.org>
 #
@@ -1530,7 +1530,7 @@ sub create_package
        local $SIG{'TERM'} = $h;
        $state->{archive} = $state->create_archive($wname, $plist->infodir);
        $state->set_status("archiving");
-       my $p = $state->progress->new_sizer($plist, $state);
+       my $p = $state->progress->new_sizer($plist);
        for my $e (@$ordered) {
                $e->create_package($state);
                $p->advance($e);