in reply to Downloading Gmail attachments - Corrupted saved file
open (FILE, ">:raw:perlio" . $att->{filename});
:raw removes default layers which may transform the data being printed. :perlio reintroduces buffering.
> instead of >> replaces existing files instead of corrupting existing files by appending to them.
Update: Added explanations.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Downloading Gmail attachments - Corrupted saved file
by casimo (Sexton) on Dec 30, 2009 at 23:52 UTC | |
by almut (Canon) on Dec 31, 2009 at 00:01 UTC | |
by casimo (Sexton) on Dec 31, 2009 at 00:22 UTC |