|
From: <sv...@va...> - 2007-05-01 14:18:48
|
Author: sewardj
Date: 2007-05-01 15:18:48 +0100 (Tue, 01 May 2007)
New Revision: 6722
Log:
Avoid compilation warnings with gcc-4.2.
Modified:
trunk/coregrind/m_debuginfo/readelf.c
trunk/coregrind/m_scheduler/scheduler.c
trunk/coregrind/m_ume.c
Modified: trunk/coregrind/m_debuginfo/readelf.c
===================================================================
--- trunk/coregrind/m_debuginfo/readelf.c 2007-05-01 13:44:08 UTC (rev 6721)
+++ trunk/coregrind/m_debuginfo/readelf.c 2007-05-01 14:18:48 UTC (rev 6722)
@@ -244,7 +244,7 @@
return False;
/* Ignore if nameless, or zero-sized. */
- if (sym->st_name == (ElfXX_Word)NULL
+ if (sym->st_name == (ElfXX_Word)0
|| /* VG_(strlen)(sym_name) == 0 */
/* equivalent but cheaper ... */
sym_name[0] == 0
Modified: trunk/coregrind/m_scheduler/scheduler.c
===================================================================
--- trunk/coregrind/m_scheduler/scheduler.c 2007-05-01 13:44:08 UTC (rev 6721)
+++ trunk/coregrind/m_scheduler/scheduler.c 2007-05-01 14:18:48 UTC (rev 6722)
@@ -760,7 +760,7 @@
static void handle_syscall(ThreadId tid)
{
- ThreadState *tst = VG_(get_ThreadState)(tid);
+ ThreadState * volatile tst = VG_(get_ThreadState)(tid);
Bool jumped;
/* Syscall may or may not block; either way, it will be
Modified: trunk/coregrind/m_ume.c
===================================================================
--- trunk/coregrind/m_ume.c 2007-05-01 13:44:08 UTC (rev 6721)
+++ trunk/coregrind/m_ume.c 2007-05-01 14:18:48 UTC (rev 6722)
@@ -835,7 +835,8 @@
ret = do_exec_inner(exe_name, info);
if (0 != ret) {
- ret = do_exec_shell_followup(ret, (Char*)exe_name, info);
+ Char* exe_name_casted = (Char*)exe_name;
+ ret = do_exec_shell_followup(ret, exe_name_casted, info);
}
return ret;
}
|