home *** CD-ROM | disk | FTP | other *** search
/ Netrunner 2004 October / NETRUNNER0410.ISO / regular / ActivePerl-5.8.4.810-MSWin32-x86.msi / _f7c21aa8eac900f10ef24630d12d8984 < prev    next >
Encoding:
Text File  |  2004-06-01  |  928 b   |  28 lines

  1. # NOTE: Derived from ..\..\lib\Storable.pm.
  2. # Changes made here will be lost when autosplit is run again.
  3. # See AutoSplit.pm.
  4. package Storable;
  5.  
  6. #line 240 "..\..\lib\Storable.pm (autosplit into ..\..\lib\auto\Storable\_store_fd.al)"
  7. # Internal store routine on opened file descriptor
  8. sub _store_fd {
  9.     my $xsptr = shift;
  10.     my $self = shift;
  11.     my ($file) = @_;
  12.     logcroak "not a reference" unless ref($self);
  13.     logcroak "too many arguments" unless @_ == 1;    # No @foo in arglist
  14.     my $fd = fileno($file);
  15.     logcroak "not a valid file descriptor" unless defined $fd;
  16.     my $da = $@;                # Don't mess if called from exception handler
  17.     my $ret;
  18.     # Call C routine nstore or pstore, depending on network order
  19.     eval { $ret = &$xsptr($file, $self) };
  20.     logcroak $@ if $@ =~ s/\.?\n$/,/;
  21.     local $\; print $file '';    # Autoflush the file if wanted
  22.     $@ = $da;
  23.     return $ret ? $ret : undef;
  24. }
  25.  
  26. # end of Storable::_store_fd
  27. 1;
  28.