[前][次][番号順一覧][スレッド一覧]

ruby-changes:17370

From: usa <ko1@a...>
Date: Thu, 30 Sep 2010 09:40:17 +0900 (JST)
Subject: [ruby-changes:17370] Ruby:r29374 (trunk): * vm_dump.c (dump_thread): fixed wrong type of return value of

usa	2010-09-30 09:35:23 +0900 (Thu, 30 Sep 2010)

  New Revision: 29374

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=29374

  Log:
    * vm_dump.c (dump_thread): fixed wrong type of return value of
      SymGetModuleBase64(). [ruby-dev:42306]

  Modified files:
    trunk/ChangeLog
    trunk/vm_dump.c

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 29373)
+++ ChangeLog	(revision 29374)
@@ -1,3 +1,8 @@
+Thu Sep 30 09:34:03 2010  NAKAMURA Usaku  <usa@r...>
+
+	* vm_dump.c (dump_thread): fixed wrong type of return value of
+	  SymGetModuleBase64(). [ruby-dev:42306]
+
 Wed Sep 29 21:04:05 2010  URABE Shyouhei  <shyouhei@r...>
 
 	* test/ruby/test_rubyoptions.rb (TestRubyOptions::test_script_from_stdin):
Index: vm_dump.c
===================================================================
--- vm_dump.c	(revision 29373)
+++ vm_dump.c	(revision 29374)
@@ -661,7 +661,7 @@
     BOOL (WINAPI *pSymInitialize)(HANDLE, const char *, BOOL);
     BOOL (WINAPI *pSymCleanup)(HANDLE);
     BOOL (WINAPI *pStackWalk64)(DWORD, HANDLE, HANDLE, STACKFRAME64 *, void *, PREAD_PROCESS_MEMORY_ROUTINE64, PFUNCTION_TABLE_ACCESS_ROUTINE64, PGET_MODULE_BASE_ROUTINE64, PTRANSLATE_ADDRESS_ROUTINE64);
-    BOOL (WINAPI *pSymGetModuleBase64)(HANDLE, DWORD64);
+    DWORD32 (WINAPI *pSymGetModuleBase64)(HANDLE, DWORD64);
     BOOL (WINAPI *pSymFromAddr)(HANDLE, DWORD64, DWORD64 *, SYMBOL_INFO *);
     BOOL (WINAPI *pSymGetLineFromAddr64)(HANDLE, DWORD64, DWORD *, IMAGEHLP_LINE64 *);
     HANDLE (WINAPI *pOpenThread)(DWORD, BOOL, DWORD);
@@ -674,7 +674,7 @@
     pSymInitialize = (BOOL (WINAPI *)(HANDLE, const char *, BOOL))GetProcAddress(dbghelp, "SymInitialize");
     pSymCleanup = (BOOL (WINAPI *)(HANDLE))GetProcAddress(dbghelp, "SymCleanup");
     pStackWalk64 = (BOOL (WINAPI *)(DWORD, HANDLE, HANDLE, STACKFRAME64 *, void *, PREAD_PROCESS_MEMORY_ROUTINE64, PFUNCTION_TABLE_ACCESS_ROUTINE64, PGET_MODULE_BASE_ROUTINE64, PTRANSLATE_ADDRESS_ROUTINE64))GetProcAddress(dbghelp, "StackWalk64");
-    pSymGetModuleBase64 = (BOOL (WINAPI *)(HANDLE, DWORD64))GetProcAddress(dbghelp, "SymGetModuleBase64");
+    pSymGetModuleBase64 = (DWORD32 (WINAPI *)(HANDLE, DWORD64))GetProcAddress(dbghelp, "SymGetModuleBase64");
     pSymFromAddr = (BOOL (WINAPI *)(HANDLE, DWORD64, DWORD64 *, SYMBOL_INFO *))GetProcAddress(dbghelp, "SymFromAddr");
     pSymGetLineFromAddr64 = (BOOL (WINAPI *)(HANDLE, DWORD64, DWORD *, IMAGEHLP_LINE64 *))GetProcAddress(dbghelp, "SymGetLineFromAddr64");
     pOpenThread = (HANDLE (WINAPI *)(DWORD, BOOL, DWORD))GetProcAddress(GetModuleHandle("kernel32.dll"), "OpenThread");
@@ -727,10 +727,9 @@
 			DWORD64 addr = frame.AddrPC.Offset;
 			IMAGEHLP_LINE64 line;
 
-			if (addr == frame.AddrReturn.Offset ||
-			    addr == 0 || frame.AddrReturn.Offset == 0) {
+			if (addr == frame.AddrReturn.Offset || addr == 0 ||
+			    frame.AddrReturn.Offset == 0)
 			    break;
-			}
 
 			memset(buf, 0, sizeof(buf));
 			info->SizeOfStruct = sizeof(SYMBOL_INFO);

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]