Interpreter Crash

I am using ROOT 5.34/09, this reproduces the bug:

[code]jfcaron@host184-232:~$ root -l

  • ROOT v5.34/09 *

root [0] Int_t i = 5
root [1] typeid(i).name
root.exe(51495) malloc: *** error for object 0x7f8269ab8918: incorrect checksum for freed object - object was probably modified after being freed.
*** set a breakpoint in malloc_error_break to debug
[/code]

Even more confusing, without declaring a variable, you need to try twice to make it crash:

jfcaron@host184-232:~$ root -l
*  ROOT v5.34/09  *

root [0] typeid(7).name
Error: Function typeid(7) is not defined in current scope  (tmpfile):1:
Error: Failed to evaluate typeid(7).name
*** Interpreter error recovered ***
root [1] typeid(7).name
root.exe(51450) malloc: *** error for object 0x7f9e142b9128: incorrect checksum for freed object - object was probably modified after being freed.
*** set a breakpoint in malloc_error_break to debug

While I understand getting an error message of some kind, the interpreter probably shouldn’t be crashing here, right?

I was trying to programmatically get type information about a variable (int or double for example).

Jean-François

Hi Jean-Francois,

Yes the error message should have been:Error: class type_info not defined. <typeinfo.h> must be included (tmpfile):1:. The v5.34/00 patch branch has been updated accordingly.

Cheers,
Philippe.