- Timestamp:
- 2020-10-20T11:17:11+13:00 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone2/perllib/downloaders/Z3950Download.pm
r28250 r34498 1 1 ########################################################################### 2 2 # 3 # WebDownload.pm -- base class for all the import plugins3 # Z3950Download.pm -- downloading class for z3950 protocol 4 4 # A component of the Greenstone digital library software 5 5 # from the New Zealand Digital Library Project at the … … 142 142 sub start_yaz 143 143 { 144 my ($self, $url) = @_; 145 146 print STDERR "Opening connection to $url\n"; 147 144 my ($self, $url) = @_; 145 148 146 my $yaz = $self->{'yaz'}; 149 147 … … 154 152 $self->{'YAZIN'} = *YAZIN; 155 153 156 my $strOpen = $self->open_connection("open $url"); 157 158 if (!$strOpen) { 159 print STDERR "Cannot connect to $url\n"; 160 print STDERR "<<Finished>>\n"; 161 return 0; 162 } 163 return $strOpen; 154 if (defined $url) { 155 print STDERR "Opening connection to $url\n"; 156 my $strOpen = $self->open_connection("open $url"); 157 158 if (!$strOpen) { 159 print STDERR "Cannot connect to $url\n"; 160 print STDERR "<<Finished>>\n"; 161 return 0; 162 } 163 164 return $strOpen; 165 } 166 return 1; 164 167 } 165 168 … … 389 392 $url = $self->{'url'} unless defined $url; 390 393 391 my $strOpen = $self->start_yaz(); 392 393 $strOpen = $self->run_command_with_output("open $url","^Options"); 394 #my $strOpen = $self->start_yaz(); 395 $self->start_yaz(); 396 397 my $strOpen = $self->run_command_with_output("open $url","^Options"); 394 398 395 399 $strOpen =~ s/Z> //g;
Note:
See TracChangeset
for help on using the changeset viewer.