From e9173066825d90a16ee082ff27539c85605b2fbd Mon Sep 17 00:00:00 2001 From: kichik Date: Sat, 10 May 2008 10:44:33 +0000 Subject: [PATCH] size optimization and a bit clearer code git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@5639 212acab6-be3b-0410-9dea-997c60f758d6 --- Source/exehead/Ui.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/exehead/Ui.c b/Source/exehead/Ui.c index 873edc7f..e65b2d74 100644 --- a/Source/exehead/Ui.c +++ b/Source/exehead/Ui.c @@ -985,7 +985,7 @@ static BOOL CALLBACK DirProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar char *root; int error = 0; int available_set = 0; - unsigned total, available = 0xFFFFFFFF; + unsigned total, available; GetUIText(IDC_DIR,dir); if (!is_valid_instpath(dir)) @@ -1059,7 +1059,7 @@ static BOOL CALLBACK DirProc(HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lPar total = (unsigned) sumsecsfield(size_kb); - if (available < total) + if (available_set && available < total) error = NSIS_INSTDIR_NOT_ENOUGH_SPACE; if (LANG_STR_TAB(LANG_SPACE_REQ)) {