Re: [PBML] Binmode
- use File::Copy
binmode(FILE_HANDLE) This function puts FILE_HANDLE into a binary mode.
On Dec 14, 2007 11:14 PM, Gilles Beauregard <gilles@...> wrote:
> I have to copy some images on my Windows system with Perl.
> I use the following script to do so:
> $in_ = "original.gif" ;
> open (IN,"$in_") ;
> @fichier=<IN> ;
> close (IN) ;
> $out = "destination.gif" ;
> open (OUT,">$out") ;
> binmode OUT, ":raw" ;
> print OUT @fichier ;
> close (OUT) ;
> Some images are copy whithout problem, but some others are
> corrupt, some byte is missing.
> I can't figure the reason of that behavior.
> Any help are welcome.
> Gilles B.
> Webmasters helping webmasters
If you haven't found something you are willing to die for, you are not
fit to live!
Phone: +91 9980799008
email: jabirahmed@... , jabirahmed@...
yahoo jabirahmed@...,msn : jabir07@...,ICQ: 56327312, Skype:
[Non-text portions of this message have been removed]