made inttosizestr only display the + on GB shown on win9x. (sorry kichik, kinda undid some of your optimizaton -- I made this one slightly smaller though than the old one)

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1309 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
justin1014 2002-10-06 18:33:35 +00:00
parent c9f0b33f2d
commit 5b842cf3b1

View file

@ -735,9 +735,11 @@ static char * NSISCALL inttosizestr(int kb, char *str)
{
char sh=20;
char c='G';
char s=0;;
if (kb < 1024) { sh=0; c='K'; }
else if (kb < 1024*1024) { sh=10; c='M'; }
wsprintf(str+mystrlen(str),"%d.%d%cB%c",kb>>sh,((kb*10)>>sh)%10,c,GetVersion()&0x80000000?'+':' ');
else if (GetVersion()&0x80000000) s='+';//only display the + on GB shown on win9x.
wsprintf(str+mystrlen(str),"%d.%d%cB%c",kb>>sh,((kb*10)>>sh)%10,c,s);
return str;
}