This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] - tracepoint problem


hi,
this is a patch that takes care of a crash that occurs in gdb due to a
wrong type inferencing of the internal variable trace_line . it cannot be
dereferenced as a char * but must have the type built-in type  int as
shown below.

cheers
Ramana

--- gdb+dejagnu-20030821/gdb/tracepoint.c	2003-06-12 04:59:48.000000000 +0530
+++ gdb+dejagnu-20030821/gdb/tracepoint.c	2003-09-08 20:18:07.000000000 +0530
@@ -266,7 +266,7 @@
       set_internalvar (lookup_internalvar ("trace_file"),
 		       value_from_pointer (charstar, (LONGEST) 0));
       set_internalvar (lookup_internalvar ("trace_line"),
-		       value_from_pointer (builtin_type_int, (LONGEST) - 1));
+		       value_from_longest (builtin_type_int, (LONGEST) - 1));
       return;
     }

----
Ramana Radhakrishnan
Codito Technologies


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]