Jacek Caban : urlmon: Simplify get_feature_from_process.
Alexandre Julliard
julliard at winehq.org
Fri Nov 15 13:14:29 CST 2013
Module: wine
Branch: master
Commit: c356d450fbf05f76c320f9977cef8829ab5d1c24
URL: http://source.winehq.org/git/wine.git/?a=commit;h=c356d450fbf05f76c320f9977cef8829ab5d1c24
Author: Jacek Caban <jacek at codeweavers.com>
Date: Fri Nov 15 13:34:08 2013 +0100
urlmon: Simplify get_feature_from_process.
---
dlls/urlmon/internet.c | 13 ++++---------
1 files changed, 4 insertions(+), 9 deletions(-)
diff --git a/dlls/urlmon/internet.c b/dlls/urlmon/internet.c
index d4a49b5..e5d41b6 100644
--- a/dlls/urlmon/internet.c
+++ b/dlls/urlmon/internet.c
@@ -637,22 +637,17 @@ static HRESULT load_process_feature(INTERNETFEATURELIST feature)
static HRESULT get_feature_from_process(INTERNETFEATURELIST feature)
{
- HRESULT hres;
+ HRESULT hres = S_OK;
EnterCriticalSection(&process_features_cs);
/* Try loading the feature from the registry, if it hasn't already
* been done.
*/
- if(process_feature_controls[feature].check_registry) {
+ if(process_feature_controls[feature].check_registry)
hres = load_process_feature(feature);
- if(FAILED(hres)) {
- LeaveCriticalSection(&process_features_cs);
- return hres;
- }
- }
-
- hres = process_feature_controls[feature].enabled ? S_OK : S_FALSE;
+ if(SUCCEEDED(hres))
+ hres = process_feature_controls[feature].enabled ? S_OK : S_FALSE;
LeaveCriticalSection(&process_features_cs);
More information about the wine-cvs
mailing list