Menu

#430 gscan2pdf not running under Linux Mint 22beta

v1.0_(example)
closed-fixed
nobody
None
5
2024-07-07
2024-07-07
No

Linux Mint 22 Beta running in virtual machine with kvm/qemu
Installed gscan2pdf 2.13.3-1 from https:\sourceforge.net/projects/gscan2pdf/ .

After starting from command line the program exits with error „Error: cannot close /etc/upstream-release“.

see also: attached log and Linux Mint 22beta ticket https://github.com/linuxmint/mint22-beta/issues/103

1 Attachments
log

Discussion

  • Jeffrey Ratcliffe

    Thanks for the report. This patch fixes things for me:

    diff --git a/bin/gscan2pdf b/bin/gscan2pdf
    index ca3513ea..a509383c 100755
    --- a/bin/gscan2pdf
    +++ b/bin/gscan2pdf
    @@ -188,17 +188,26 @@ my ( $rc, %SETTING ) = read_config();
    
     set_up_test_mode();
    
    -$logger->info("Operating system: $OSNAME");
    -if ( $OSNAME eq 'linux' ) {
    
    -    my @files = glob '/etc/*-release';
    -    for (@files) {
    -        my $output = Gscan2pdf::Document::slurp($_);
    -        if ( defined $output ) {
    -            chomp $output;
    -            $logger->info($output);
    +sub rlog_release {
    +    my @files = @_;
    +    for my $file (@files) {
    +        if ( -d $file ) {
    +            rlog_release( glob "$file/*" );
    +        }
    +        else {
    +            my $output = Gscan2pdf::Document::slurp($file);
    +            if ( defined $output ) {
    +                chomp $output;
    +                $logger->info($output);
    +            }
             }
         }
     }
    +
    +$logger->info("Operating system: $OSNAME");
    +if ( $OSNAME eq 'linux' ) {
    +    rlog_release( glob '/etc/*-release' );
    +}
     $logger->info("Perl version $PERL_VERSION");
     $logger->info("Glib-Perl version $Glib::VERSION");
     $logger->info(
    
     
  • Jeffrey Ratcliffe

    • status: open --> closed-fixed
     
  • Robert Geierhofer

    Checked it on my system and it works. Thanks a lot.

     

Log in to post a comment.

MongoDB Logo MongoDB