Archive: NSIS Bug..:( Sizes wrong!


NSIS Bug..:( Sizes wrong!
OK I thought this was just a ZIP2EXE bug but it is the same in normal NSIS.

When selecting many file it works out the wrong size of teh files.

When creating a EXE it works out the size of the unzipped exe file wrong.

It is always more by about 20-50%.

Thinking about it it maybe just rounding up to the nearest K for each file or something. I have thousands of small files and it is wrong by large amounts. Eg 391 files---total size 837KB NSIS says the install size is 1008KB.

:(

Could this be fixed. And hopefully add ZIP2EXE additional features as requested by me before.

I noticed this before with v1.96 or something when I first used NSIS but I thought it was just ZIP2EXE and it is still here on v1.98

If this is a bug I cannot beleive no-one has noticed it before.

I have only been here for 5 minutes. :);)

Is this more dodgy NullSoft code?:);)

Cheers,

Rovastar


Here is a small sample file.

Total actual uncompressed size 33.6KB Size NSIS says it is will 40KB.

Grrrr cannot upload exe files. I have renamed a zip file and attached if you are interested.


Errm I am sorry I did not email you Smile (so you could put this is in main bug report place) but I didn't know if this is a bug or not as I do not know enough about NSIS. I was actaully awaiting confirmation - of someone more knowledgeable.

Is it a bug or not?

also

I would I would suggest that you get sub-forums from in here of NSIS Wishlist and NSIS Bug reporting, etc. One open thread will get overloaded.

And way it will loads easier for you to mod.

Probably best to PMing someone at Nullsoft for this request (Justin or Steve).

Hope it helps.


Rovastar,

I'll ask Justin for a sub-Forum. Nice Idea. Didn't know this possibility.

For your bug: I guess Justin solved it in 1.98.

Made size estimation display nicer and reorganized a little bit.
-Hendri.

No you do not undersatnd Smile.

v1.98 just fixes the rounding amount.

ie 1.51 MB install was dispalyed as 1MB It was using integers. now it goes to 0.1 of the unit value. Now with v1.98 it displays 1.5MB so it looks nicer.

Not fixing the amount being wrong in the first place.

My Bug is that it actually displays the wrong amount to be installed.

Have a look at my little test NSIS or make one yourself.
You notice it more with lots of small files.

CAn someone test this and confirm or deny? It looks a big bug to me.


I tested it in NSIS 1.98 and indeed the problem exists! So it's a bug...

And indeed i did not understand. Sorry, I did not read the whole thread. I saw something about filesize and since the thread was long...

So it's a bug... :(

-Hendri.


OK no problem. At least I wasn't doing something wrong.:)

:) I cannot believe that that bug has been there all the time and no-one has noticed. LOL.

There must be thousands upon thousands of programs using the NSIS installers out with the incorrect install size. :):D

I hope it is fixed soon.

Cheers,

Rovastar


Yes, it does round the size of files up to the nearest KB.

I personally think this is fair to do, since small files typically use as much as 4k or even 32k of space...

-Justin


:( :down:
For my situation it is a mess though as I have 1000's of small (2 to 5k) files and want to use NSIS (too help support Nullsoft (MilkDrop) stuff too!). It looks unprofessional.

But it is NOT just samll files. What about large installs as ALL files are rounded up.

If you have 1000 files and they are all rounded up then the size of the install will display typicially 0.5MB larger than it actually is. (0.5 being the average fraction of a KB that each file is over)

This is just wrong??!?

Surely it is not that hard to work out before you compile/create the exe of the correct size? :confused: You could do you interger rounding after it has added up all the files. It would only take a fraction of a second of CPU time to calculte without the rounding.

If you really will not see this a bug will could you at least make an option for displaying the correct install size?

NSIS is a well used and respected install method for all sorts of things everywhere. Big and small installs with large and small files.
Surely you should cater for all?


Rovastar,

If you take a directory containing your 1000 small files, then in explorer right-click and select properties; there are two figures shown - 'Size' and 'Size on disk'. It's this second figure that NSIS attempts to estimate; as this is the actual hard disk space used by those files - and the end-user would need at least that amount of hard disk space free to be able to install those files, even if the logical sizes of all the files added together is a lot less.

Therefore I think NSIS currently does the Right Thing.

--
Dave.


Arrh OK I see what you mean now.

Sorry I may have missed the point a little with Justin comments. Sorry, I got you now.

So it is a rough estimation of the size of the install.

For one of my test set of files
Files: 684
SIze: 1.13MB
Size On Disk 2.70MB
NSIS estimated size: 1.5MB

Then...

Is it all possible to work out the 'Size' and 'Size on disk' before it is installed? as this would keep every happy.:)

Or does it depened on your OS/File Format etc. ANd if it does could you work it out it out give that information (accessing winver etc) on the fly?


Is it all possible to work out the 'Size' and 'Size on disk' before it is installed? as this would keep every happy.
Or does it depened on your OS/File Format etc. ANd if it does could you work it out it out give that information (accessing winver etc) on the fly?
It can get pretty complicated. The installing machine may always be a Windows machine, but the destination directory could be a drive/folder on a network server where the cluster sizes can vary quite widely.

IMHO NSIS is doing the best it can on size estimation.

small files typically use as much as 4k or even 32k of space...
I didn't think of this, but of course. The current estimation is the best! No bugs!

-Hendri.