Re: [Gambas-user] problems in trie class
Brought to you by:
gambas
|
From: Charlie R. <Kar...@Fe...> - 2014-11-18 21:34:55
|
Am Dienstag, den 18.11.2014, 21:48 +0100 schrieb Tobias Boege:
> On Tue, 18 Nov 2014, Karl Reinl wrote:
> > Salut Tobi,
> >
> > played with you trie example (trietest)
> >
>
> I'm glad to hear that :-)
>
> >
> > it crash if
> > p = h.GetPrefix("texte") find nothing (p=null), even when change
> > to p = h.GetPrefix("Texte")
> >
> > My change is h["texte"] to h["Texte"] (source attached)
>
> Not so glad about that...
>
> Did it really crash (i.e. segfault or abort or ...)? When I run the project
> it stops at line 25 with the error "Null object" which is to be expected
> because the prefix "texte" doesn't exist anymore after your changes. If I
> change line 25 to p = h.GetPrefix("Texte"), then it runs through flawlessly
> here.
>
It is a #11, CRASH REPORT windows opens
> If it really crashes, I need to know your Gambas version / revision and your
> system specs, especially your 32- or 64-bitness. It would also help if you
> provided a gdb backtrace and a valgrind log of the crash. Do you know how to
> do that?
>
[System]
Gambas=3.6.90 -----------------> rev.6647
OperatingSystem=Linux
Kernel=3.2.0-70-generic
Architecture=x86 ------------------> 32 bit
Distribution=Ubuntu 12.04.5 LTS
Desktop=GNOME
Theme=QPlastique
Language=de_DE.UTF-8
Memory=3025M
[Libraries]
Cairo=libcairo.so.2.11000.2
Curl=libcurl.so.4.2.0
DBus=libdbus-1.so.3.5.8
GStreamer=libgstreamer-0.10.so.0.30.0
GTK+3=libgtk-3.so.0.400.2
GTK+=libgtk-x11-2.0.so.0.2400.10
Poppler=libpoppler.so.19.0.0
Qt4=libQtCore.so.4.8.1
SDL=libSDL-1.2.so.0.11.3
> Regards,
> Tobi
>
(gdb) run
Starting program: /usr/bin/gbx3
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1".
-> root
q -> p
Texte -> french
tall -> small
term -> 2+3
test -> tomorrow
text -> words
Program received signal SIGSEGV, Segmentation fault.
0x00337331 in destroy_trie (trie=0x80b53ac, dtor=0x3379f8 <value_dtor>)
at trie.c:256
256 destroy_trie(trie->children[i], dtor);
(gdb) bt
#0 0x00337331 in destroy_trie (trie=0x80b53ac, dtor=0x3379f8
<value_dtor>)
at trie.c:256
#1 0x00338368 in Trie_free (_object=0x80aeeec, _param=0xb74a8050)
at c_trie.c:68
#2 0x08051f54 in EXEC_native () at gbx_exec.c:1366
#3 0x08052657 in EXEC_special (special=1, class=0x80b1884,
object=<optimized out>, nparam=0, drop=1 '\001') at gbx_exec.c:1674
#4 0x080527d2 in EXEC_special_inheritance (special=1, class=0x80b1884,
object=0x80aeeec, nparam=0, drop=1 '\001') at gbx_exec.c:1730
#5 0x08055895 in CLASS_free (object=0x80aeeec) at gbx_class.c:754
#6 0x08050175 in RELEASE_many (value=<optimized out>, n=0) at
gbx_exec.c:240
#7 0x08050cf0 in EXEC_leave_drop () at gbx_exec.c:795
#8 0x080514fb in EXEC_function_loop () at gbx_exec.c:1053
#9 0x08051826 in EXEC_function_real () at gbx_exec.c:895
#10 0x0804b568 in main (argc=1457883477, argv=0xbffff384) at gbx.c:416
(gdb)
but I have to say also this. I can NOT run the IDE with gdb
:~/src/gambas/3/gambas-svn30/app/src/gambas3$ gdb gbx3
GNU gdb (Ubuntu/Linaro 7.4-2012.04-0ubuntu2.1) 7.4-2012.04
Copyright (C) 2012 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show
copying"
and "show warranty" for details.
This GDB was configured as "i686-linux-gnu".
For bug reporting instructions, please see:
<http://bugs.launchpad.net/gdb-linaro/>...
Reading symbols from /usr/bin/gbx3...done.
(gdb) run
Starting program: /usr/bin/gbx3
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/i386-linux-gnu/libthread_db.so.1".
ERROR: #2: Cannot load class 'AngleBox': Unable to load class file
[Inferior 1 (process 7146) exited with code 01]
(gdb)
--
Amicalement
Charlie
|