I fixed the db lookup bug, it was due to having 2 libappstream.so on the system, it worked by specifying the LD_LIBRARY_PATH (without using sudo).
Now, with the proper libraries, I get such a crash when opening the db.
$ gdb --args appstreamcli search kalgebra
Reading symbols from appstreamcli...done.
(gdb) r
Starting program: /home/kde-devel/kde5/bin/appstreamcli search kalgebra
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/usr/lib/libthread_db.so.1".
terminate called after throwing an instance of 'std::invalid_argument'
what(): stoi
Program received signal SIGABRT, Aborted.
0x00007ffff60445f8 in raise () from /usr/lib/libc.so.6
(gdb) where
#0 0x00007ffff60445f8 in raise () from /usr/lib/libc.so.6
#1 0x00007ffff6045a7a in abort () from /usr/lib/libc.so.6
#2 0x00007ffff4e53b3d in __gnu_cxx::__verbose_terminate_handler () at /build/gcc/src/gcc-5.2.0/libstdc++-v3/libsupc++/vterminate.cc:95
#3 0x00007ffff4e51996 in __cxxabiv1::__terminate (handler=<optimized out>) at /build/gcc/src/gcc-5.2.0/libstdc++-v3/libsupc++/eh_terminate.cc:47
#4 0x00007ffff4e519e1 in std::terminate () at /build/gcc/src/gcc-5.2.0/libstdc++-v3/libsupc++/eh_terminate.cc:57
#5 0x00007ffff4e51bf8 in __cxxabiv1::__cxa_throw (obj=obj@entry=0x637690, tinfo=0x7ffff5138aa8 <typeinfo for std::invalid_argument>,
dest=0x7ffff4e67140 <std::invalid_argument::~invalid_argument()>) at /build/gcc/src/gcc-5.2.0/libstdc++-v3/libsupc++/eh_throw.cc:87
#6 0x00007ffff4e7a9df in std::__throw_invalid_argument (__s=0x7ffff6fe5ed9 "stoi") at /build/gcc/src/gcc-5.2.0/libstdc++-v3/src/c++11/functexcept.cc:82
#7 0x00007ffff6fcb8c2 in __gnu_cxx::__stoa<long, int, char, int> (__convf=0x7ffff60482a0 <strtoq>, __name=0x7ffff6fe5ed9 "stoi",
__str=0x7ffff5145218 <std::string::_Rep::_S_empty_rep_storage+24> "", __idx=0x0) at /usr/include/c++/5.2.0/ext/string_conversions.h:65
#8 0x00007ffff6fcb759 in std::stoi (__str="", __idx=0x0, __base=10) at /usr/include/c++/5.2.0/bits/basic_string.h:5258
#9 0x00007ffff6fc79a5 in DatabaseRead::open (this=0x629670, dbPath=0x6296b0 "/var/cache/app-info/xapian/default")
at /home/kde-devel/frameworks/appstream/src/xapian/database-read.cpp:66
#10 0x00007ffff6fd1009 in xa_database_read_open (db=0x629670, db_path=0x6296b0 "/var/cache/app-info/xapian/default")
at /home/kde-devel/frameworks/appstream/src/xapian/database-cwrap.cpp:33
#11 0x00007ffff6fdbfa6 in as_database_real_open (db=0x62a020) at /home/kde-devel/frameworks/appstream/src/as-database.c:105
#12 0x00007ffff6fdc011 in as_database_open (db=0x62a020) at /home/kde-devel/frameworks/appstream/src/as-database.c:117
#13 0x0000000000404257 in ascli_search_component (dbpath=0x0, search_term=0x7fffffffe7bb "kalgebra", detailed=0) at /home/kde-devel/frameworks/appstream/tools/ascli-mdata-actions.c:157
#14 0x0000000000403244 in as_client_run (argv=0x7fffffffe468, argc=3) at /home/kde-devel/frameworks/appstream/tools/appstream-cli.c:151
#15 0x0000000000403482 in main (argc=3, argv=0x7fffffffe468) at /home/kde-devel/frameworks/appstream/tools/appstream-cli.c:199
The text was updated successfully, but these errors were encountered:
I fixed the db lookup bug, it was due to having 2 libappstream.so on the system, it worked by specifying the LD_LIBRARY_PATH (without using sudo).
Now, with the proper libraries, I get such a crash when opening the db.
The text was updated successfully, but these errors were encountered: