I haven't looked deeper, but some comments may help you find the offending code:
And the error you're getting should be related to this statement:
that will produce a negative size eventually if $fsize is not a multiple of $size.$fsize-=$size;
Update: as pointed by johngg, I messed up things thinking about a pair read/write when there's only sysread/syswrite in Perl. print is just fine as a counterpart of read.
In reply to Re: File splitting script
by ferreira
in thread File splitting script
by Alien
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |