[TAPI32] Sync with Wine Staging 3.3. CORE-14434
[reactos.git] / dll / win32 / tapi32 / assisted.c
index 960081e..57c24e8 100644 (file)
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
  */
 
-#include "precomp.h"
+#include "config.h"
+#include "wine/port.h"
+
+#include <stdarg.h>
+#include <stdio.h>
+#include "windef.h"
+#include "winbase.h"
+#include "wingdi.h"
+#include "winreg.h"
+#include "objbase.h"
+#include "tapi.h"
+#include "wine/unicode.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(tapi);
 
 /***********************************************************************
  *      tapiGetLocationInfoW (TAPI32.@)
@@ -46,7 +60,7 @@ DWORD WINAPI tapiGetLocationInfoW(LPWSTR countrycode, LPWSTR citycode)
          'C','u','r','r','e','n','t','V','e','r','s','i','o','n','\\',
          'T','e','l','e','p','h','o','n','y','\\','L','o','c','a','t','i','o','n','s',0};
 
-    if(!RegOpenKeyW(HKEY_LOCAL_MACHINE, locations_keyW, &hkey) != ERROR_SUCCESS) {
+    if(RegOpenKeyW(HKEY_LOCAL_MACHINE, locations_keyW, &hkey) == ERROR_SUCCESS) {
         valsize = sizeof( DWORD);
         if(!RegQueryValueExW(hkey, currentidW, 0, &type, (LPBYTE) &currid, &valsize) &&
            type == REG_DWORD) {