Changeset 22855

Show
Ignore:
Timestamp:
06.09.2010 17:26:46 (9 years ago)
Author:
davidb
Message:

added ':utf8' to call to open file handle

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/perllib/doc.pm

    r22294 r22855  
    276276    my ($filename) = @_; 
    277277 
     278 
    278279    my $osexe = &util::get_os_exe(); 
    279280 
     
    282283 
    283284    my $result = "NULL"; 
     285 
    284286     
    285287    if (-e "$hashfile_exe") { 
     
    352354        # "hash" OID - feed file to hashfile.exe 
    353355        my $filename = $self->get_filename_for_hashing(); 
     356 
    354357        # -z: don't want to hash on the file if it is zero size 
    355358        if (defined($filename) && -e $filename && !-z $filename) { 
     
    361364        if (!$hash_on_file) { 
    362365        my $filename = &util::get_tmp_filename(); 
    363         if (!open (OUTFILE, ">$filename")) { 
     366        if (!open (OUTFILE, ">:utf8", $filename)) { 
    364367            print STDERR "doc::set_OID could not write to $filename\n"; 
    365368        } else {