]> granicus.if.org Git - php/commitdiff
fix incompatible pointer types
authorAnatol Belski <ab@php.net>
Mon, 17 Nov 2014 07:48:32 +0000 (08:48 +0100)
committerAnatol Belski <ab@php.net>
Mon, 17 Nov 2014 08:33:58 +0000 (09:33 +0100)
Zend/zend_execute_API.c

index ef4835f9af50ef33bbfbcda5878e692c23c87626..1f3cab24bfdbc793fbb779d28d962039f8dc0d26 100644 (file)
@@ -1236,6 +1236,10 @@ ZEND_API void zend_timeout(int dummy) /* {{{ */
 #ifdef ZEND_WIN32
 static LRESULT CALLBACK zend_timeout_WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam) /* {{{ */
 {
+#ifdef ZTS
+       THREAD_T thread_id = (THREAD_T)wParam;
+#endif
+
        switch (message) {
                case WM_DESTROY:
                        PostQuitMessage(0);
@@ -1250,7 +1254,7 @@ static LRESULT CALLBACK zend_timeout_WndProc(HWND hWnd, UINT message, WPARAM wPa
 #endif
                                SetTimer(timeout_window, wParam, lParam*1000, NULL);
 #ifdef ZTS
-                               tsrm_ls = ts_resource_ex(0, &wParam);
+                               tsrm_ls = ts_resource_ex(0, &thread_id);
                                if (!tsrm_ls) {
                                        /* shouldn't normally happen */
                                        break;
@@ -1267,7 +1271,7 @@ static LRESULT CALLBACK zend_timeout_WndProc(HWND hWnd, UINT message, WPARAM wPa
 #ifdef ZTS
                                void ***tsrm_ls;
 
-                               tsrm_ls = ts_resource_ex(0, &wParam);
+                               tsrm_ls = ts_resource_ex(0, &thread_id);
                                if (!tsrm_ls) {
                                        /* Thread died before receiving its timeout? */
                                        break;