mirror of
				https://github.com/chibicitiberiu/rainmeter-studio.git
				synced 2024-02-24 04:33:31 +00:00 
			
		
		
		
	Added NULL checks for the CConfigParser::ReadString()'s parameters (http://code.google.com/p/rainmeter/issues/detail?id=105).
The font and registry handle are now free'ed properly if Initialize() is called multiple times.
This commit is contained in:
		| @@ -136,6 +136,19 @@ const std::wstring& CConfigParser::ReadString(LPCTSTR section, LPCTSTR key, LPCT | ||||
| { | ||||
| 	static std::wstring result; | ||||
|  | ||||
| 	if (section == NULL) | ||||
| 	{ | ||||
| 		section = L""; | ||||
| 	} | ||||
| 	if (key == NULL) | ||||
| 	{ | ||||
| 		key = L""; | ||||
| 	} | ||||
| 	if (defValue == NULL) | ||||
| 	{ | ||||
| 		defValue = L""; | ||||
| 	} | ||||
|  | ||||
| 	result = GetValue(section, key, defValue); | ||||
| 	if (result == defValue) | ||||
| 	{ | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Kimmo Pekkola
					Kimmo Pekkola