Skip to content

Commit 1dcabe0

Browse files
committed
gdb eval with return type since debugger may not have source code to resolve
1 parent b11d14d commit 1dcabe0

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

tools/photongdb.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -52,18 +52,18 @@ def cprint(stat, *args):
5252

5353

5454
def get_next_ready(p):
55-
return gdb.parse_and_eval("gdb_get_next_thread((void*){})".format(p))
55+
return gdb.parse_and_eval("(void*)gdb_get_next_thread((void*){})".format(p))
5656

5757

5858
def get_current():
59-
return gdb.parse_and_eval("gdb_get_current_thread()")
59+
return gdb.parse_and_eval("(void*)gdb_get_current_thread()")
6060

6161

6262
def get_vcpu(p):
63-
return gdb.parse_and_eval("gdb_get_vcpu((void*){})".format(p))
63+
return gdb.parse_and_eval("(void*)gdb_get_vcpu((void*){})".format(p))
6464

6565
def get_thread_stack_ptr(p):
66-
return gdb.parse_and_eval("gdb_get_thread_stack_ptr((void*){})".format(p))
66+
return gdb.parse_and_eval("(void*)gdb_get_thread_stack_ptr((void*){})".format(p))
6767

6868
def in_sleep(q):
6969
size = int(gdb.parse_and_eval("(size_t)gdb_get_sleepq_size((void*){})".format(q)))

0 commit comments

Comments
 (0)