[BUG_FIXED] Fix a file detection bug on opening file.

git-svn-id: svn://svn.tuxfamily.org/svnroot/notepadplus/repository/trunk@901 f5eea248-9336-0410-98b8-ebc06183d4e3
This commit is contained in:
Don Ho 2012-04-23 23:49:25 +00:00
parent 71e2f0c9e3
commit 74084db9a8
3 changed files with 947 additions and 304 deletions

File diff suppressed because it is too large Load Diff

View File

@ -862,7 +862,7 @@ int Notepad_plus::getHtmlXmlEncoding(const TCHAR *fileName) const
NppParameters *pNppParamInst = NppParameters::getInstance();
LangType langT = pNppParamInst->getLangFromExt(ext);
if (langT != L_XML && langT != L_HTML && langT == L_PHP)
if ((langT != L_XML) && (langT != L_HTML))
return -1;
// Get the begining of file data

View File

@ -622,13 +622,6 @@ private:
return randomNumber;
return (rand() % rangeMax);
};
/*
static int getRandomNumber(int rangeMax) {
srand((unsigned int)time(NULL));
return ((int)((double)rand() / ((double)RAND_MAX + 1) * rangeMax));
};
*/
};