Liz:

I put together some sample code below that generates the error to which
I've been referring using Perl 5.8.4RC1.  It should run fine on 5.8.0. 
My output is:

The new filehandle is: *main::FH
The number of items in the active user's data array is/are: 2
1111
Can't upgrade that kind of scalar at 584error.pl line 25.


__CODE__

#!/usr/local/bin/perl -w

use strict;
use warnings;

use threads;
use threads::shared;

my %foo : shared;
my $port = 1111;
my $rec = "bar";

my $fh_str = '>> /yourpath/port_'.$port; # add your path here
my $UDP_fh = &UDP_fh_open($fh_str);
print "The new filehandle is: $UDP_fh\n";

my @au_data_array : shared  = ($port, $UDP_fh);
my $au_data_array_ref = [EMAIL PROTECTED];
my $num_au_items = @au_data_array;
print "Number of items in array: $num_au_items\n";

$foo{$rec} = $au_data_array_ref; 

print "$foo{$rec}[0]\n";
print "$foo{$rec}[1]\n";

sub UDP_fh_open {
    my $path = shift;
    open(FH, $path) || die $!;  
    return *FH; 
} # end sub UDP_fh_open


Reply via email to