mIRC Homepage
Posted By: tontito $file().size problem on 6.16 - 26/06/05 09:03 PM
Hello,
i noticed this problem on 6.16 and i had a look at the page search where i found this
looks like the problem is solved with this version but i found a combination where we can see it.

If the file is been used atm (read or write access) and you try to see its size, you get a negative number.

To test this situation the best way is to have a loop reading the file, and maybe another mirc trying to check its file size (can be same mirc)

thanks for your attention
Posted By: DaveC Re: $file().size problem on 6.16 - 26/06/05 10:45 PM
I cant make this happen. (not saying it didnt happen)
I did however get some results showing NO file size returned, and then the one writing and deleting errored with an access denied to the file, I would assume this is of course becuase i was using /WRITE which if you alter any of the lines besides adding one at the end, rebuilds the entire file (using a temp name) then deletes the original and renames the temp one into it.
That would explain the moments of NO file size, and liekly even the access denied.
I also tried it using another langauge to write and delete from the file, with this the file size remained correct at all times.
Posted By: tontito Re: $file().size problem on 6.16 - 28/06/05 11:37 AM
I noticed this problem when the file size is bigegr than 2G and smaller than 4G.
I didn't tryed it with > 4G
One of the tests i was reading data from the file and checking the size and the other test i was increasing the file size from 2G to 4G and checking also the file size.
Both gave me the problem.

Thanks for your feedback Davec
Posted By: Riamus2 Re: $file().size problem on 6.16 - 28/06/05 12:45 PM
I do know there are some issues with files over 2GB and FAT32 (not mIRC-related). I'm not sure if that's the problem, or if this problem is something mIRC-related.
Posted By: Mary_juana Re: $file().size problem on 6.16 - 28/06/05 01:12 PM
i'm pretty sure this is a windows problem, similar events have happened to friends some time ago.
Posted By: tontito Re: $file().size problem on 6.16 - 29/06/05 08:24 PM
hello and thanks for all your feedback
but, my tests where made on ntfs...so i belive it can be mirc related.

thanks again
Posted By: Hrung Re: $file().size problem on 6.16 - 29/06/05 10:34 PM
Verified.. at least insofar as $file().size gave the wrong file size (-130365440) as windows was busy making a copy of a 3.87 GB file. Once the file finished copying, mIRC got the file size right.

mIRC 6.16/winXP+sp2
Posted By: Sat Re: $file().size problem on 6.16 - 29/06/05 10:41 PM
Quote:
If the file is been used atm (read or write access) and you try to see its size, you get a negative number.

Confirmed, and yes, this really is a bug in mIRC, not in Windows.
© mIRC Discussion Forums