Git Product home page Git Product logo

rct's Introduction

rct

Travis build status

A set of c++ tools that provide nicer (more Qt-like) APIs on top of stl classes released under a BSD license.

Build Instructions

rct uses the CMake build system.

Unix-Like Systems

On Unix-like systems, building rct is straightforward. Just use cmake and your preferred compiler and build system.

Windows

Windows support is not complete yet:

  • Not all classes are ported to Windows
  • Building is only possible with mingw from MSYS2.
  • To build the tests, you will also need to build cppunit yourself.

Once you installed all the prerequisites, you can use cmake to generate "MSYS Makefiles" or "MinGW Makefiles" (both work) to build the library.

rct's People

Contributors

adamwg avatar andersbakken avatar bbannier avatar casch-at avatar cynary avatar dushistov avatar emdeesee avatar gei0r avatar gicmo avatar jhanssen avatar jhanssen-work avatar keryell avatar kradih avatar louxiu avatar lyuts avatar marxin avatar mckellyln avatar mikezackles avatar oystedal avatar pradhanpk avatar red-portal avatar smoofra avatar solomonchild avatar spacemoose avatar terranpro avatar thejj avatar tom-seddon avatar tuxillo avatar yoshimoto avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rct's Issues

Compilation error

I got the following error:

In file included from /home/hong/src/rct/rct/EventLoop.cpp:23:0:
/home/hong/src/rct/rct/EventLoop.cpp: In member function ‘unsigned int EventLoop::processSocket(int, int)’:
/home/hong/src/rct/rct/EventLoop.cpp:633:75: error: cannot convert ‘std::queue<Event*>’ to ‘epoll_event*’ for argument ‘2’ to ‘int epoll_wait(i
nt, epoll_event*, int, int)’
     eintrwrap(eventCount, epoll_wait(processFd, events, MaxEvents, timeout));

FileSystemWatcher_kqueue.cpp compilation fails on Freebsd

Hi, I've just installed rtags on my FreeBSD VM but found an issue that prevents rct to compile.

rct/FileSystemWatcher_kqueue.cpp (line 247)

                    error("FileSystemWatcher::notifyReadyRead() kevent element failed for '%s' (%ld) %s",
                          p.constData(), event.data, Rct::strerror(event.data));

should be

                    error("FileSystemWatcher::notifyReadyRead() kevent element failed for '%s' (%ld) %s",
                          p.constData(), event.data, Rct::strerror(event.data).constData());

Otherwise compiler complains you can't pass a non-trivial object of type String to a variadic function.

Use POSIX instead of System V

It seems semaphores are implemented using System V semaphores.
I suggest porting them to POSIX semaphores.
Those are much simpler, and easier to port to Win32.

gcc wrapper script should rc --compile during link-time

I use -c for compiling and then link the object files separately. So, during the link invocation of g++, I receive:

Source::parse No file for /usr/bin/g++

in the log (with verbose logging). Seems like this could be avoided, but it may be harmless.

clang 5.0 C++11 support not detected

2016-11-25_21-05-12

This error occurs when compiling CXX_COMPILER clang 5.0, C_COMPILER gcc 6.0

2017-02-06_19-19-13

I recreated the same cmake test,
And compiled it just as below

2016-11-08_19-35-54-1

with flags -std=c++11, -pthread it compiles fine.

Compile error with g++ 4.7

/rct/rct/EventLoop.cpp:93:32: error: 'this' was not captured for this lambda function
CMakeFiles/rct.dir/build.make:215: recipe for target 'CMakeFiles/rct.dir/rct/EventLoop.cpp.o' failed
make[2]: *** [CMakeFiles/rct.dir/rct/EventLoop.cpp.o] Error 1

make test fails on an assert

Using gcc version 6.3.1 20170202 I see:

$ make test
make test
Running tests...
Test project /home/marxin/Programming/rct/build
    Start 1: unittests
1/1 Test #1: unittests ........................***Exception: Other  1.16 sec
$ cat Testing/Temporary/LastTest.log
...
rct_tests: /home/marxin/Programming/rct/rct/Process.cpp:271: Process::~Process(): Assertion `mReturn != ReturnUnset || mPid == -1' failed.
...

Can you please take a look?

Using std::thread to implement Thread.

Hi

I'm trying to port rct to MSVC and one the many changes I need to make is porting Thread to Windows.

I have thought about replacing it's current implementation with a thin wrapper around std::thread. And using native_handle to implement support for priorities.

Would it be ok to do this? Is there any particular reason why Thread is implemented the way it is?

Returning address of local temporary object

clang 3.9 warns about the following (lots of instances, for example): https://github.com/Andersbakken/rct/blob/master/rct/Map.h#L49

Value value(const Key &key, const Value &defaultValue = Value(), bool *ok = 0) const
    {
        typename Base::const_iterator it = Base::find(key);
        if (it == Base::end()) {
            if (ok)
                *ok = false;
            return defaultValue;
        }
        if (ok)
            *ok = true;
        return it->second;
    }

Since clang-3.9 is not released yet, this might be an error, but I do think that the compiler is right on this one. defaultValue is a lvalue reference, and the value is local to the function (since it's a parameter).

"make install" fails

Steps to reproduce:

With a fresh checkout:

$ mkdir build
$ cd build
$ cmake ..
$ make
$ make install

make install fails with file INSTALL cannot find "~/rtags/src/rct/rct/DB.h".

Enhancement Request: run rp at a lower priority

I have an eight way system and my rp processes are competing with my explicit ninja build for precious resources. Since this is more or less a background tool, seems like it would be good to let the developer's primary compiler run at the higher priority by default, and rp just finishes whenever it finishes.

Is there any reason not to install these headers?

I'm trying to help packaging rtags on guix. Maintainers want to separate those sub-modules into different packages. I found that rct installs only selected headers with the following headers excluded:

rct/CpuUsage.h
rct/DataFile.h
rct/Date.h
rct/EmbeddedLinkedList.h
rct/FinishMessage.h
rct/Flags.h
rct/Hash.h
rct/LinkedList.h
rct/Map.h
rct/MemoryMappedFile.h
rct/OnDestruction.h
rct/QuitMessage.h
rct/ResponseMessage.h
rct/ScriptEngine.h
rct/StackBuffer.h
rct/WindowsUnicodeConversion.h

When building rtags with out of tree rct, some headers are needed, like Hash.h. Can we just install all the headers? If the answer is yes, I can prepare a patch now.

Add requirement when OpenSSL Headers missing?

When building rtags on a fresh Cygwin64 I had cmake finish successfully only to fail immediately when building the AES256 module in rct.

It failed to find header <openssl/evp.h>

I was missing the openssl-dev libraries, and installing them fixed the build error but...

Should there be a requirement check in rct for openssl that causes cmake to fail? Or even making that module optional?

Thanks

LICENSE.txt seems like it could use some TLC

In LICENSE.txt looks like it's been cribbed from the "Sudo License" section of http://www.linfo.org/bsd_license.html but not modified properly. For example it still says:

Products derived from this software may not be called "Sudo"

and:

Additionally, lsearch.c, fnmatch.c, getcwd.c, snprintf.c strcasecmp.c and fnmatch.3 bear the following UCB license

(these files don't exist in the rct source).

String.h function lastIndexOf return value is not correct

size_t lastIndexOf(char ch, size_t from = npos, CaseSensitivity cs = CaseSensitive) const
{
    if (cs == CaseSensitive)
        return mString.rfind(ch, from == npos ? std::string::npos : size_t(from));
    const char *data = mString.c_str();
    if (from == npos)
        from = mString.size() - 1;
    ch = tolower(ch);
    int f = static_cast<int>(from);
    while (f >= 0) {
        if (tolower(data[f]) == ch)
            return **from**;
        --f;
    }
    return npos;
}

this function should return f instead of from, from is always size() - 1.

Unexpected HUP on Unix Domain Socket: Please help/explain

Hey,

please have a look at my SocketTestSuite here (commit is 5a766d2).

I expect the client to get the server's message, but the client slot is not called.

Output on my machine:

./rct_tests
Socket Server unix listen fd= 6
registerSocket(fd= 6 mode= 1 )
process 1 events...
event 1 on fd= 3
created client socket with fd= 7
registerSocket(fd= 7 mode= 1 )
socket client 0x1ca0500 (fd= 7 ) about to connect to test_unixSocket ...
process 1 events...
event 16 on fd= 7
After connect() call, returned 0
HUP on socket 7, removing
process 1 events...
event 1 on fd= 6
SocketServer: got new connection with fd= 8
SocketClient ctor fd= 8
registerSocket(fd= 8 mode= 1 )
SENT(2) 14 BYTES to 8 : 14 11
SocketClient dtor (fd= 7 )
unregisterSocket(fd= 7 )
SocketClient dtor (fd= 8 )
unregisterSocket(fd= 8 )
unregisterSocket(fd= 6 )
SocketTestSuite.cpp:61:Assertion
Test name: SocketTestSuite::unixSockets
assertion failed
- Expression: numReadsFromClient == 1

Failures !!!
Run: 1   Failure total: 1   Failures: 1   Errors: 0

Apparently, the client gets a HUP shortly after connecting to the server. Maybe that's the problem? What gives?

/usr/lib/librtc.so should be /usr/lib64/librtc.so

On Gentoo, the multilib-strict sanity check fails:

multilib-strict check fails on gentoo:

 * ERROR: dev-libs/rct-9999::sft failed:
 *   multilib-strict check failed!
 * 
 * Call stack:
 *   misc-functions.sh, line 605:  Called install_qa_check
 *   misc-functions.sh, line 217:  Called source 'install_symlink_html_docs'
 *   80multilib-strict, line  46:  Called multilib_strict_check
 *   80multilib-strict, line  42:  Called die
 * The specific snippet of code:
 *   		[[ ${abort} == yes ]] && die "multilib-strict check failed!"

This is because the libdir is /usr/lib and not /usr/lib64.
This can be fixed by using ${CMAKE_INSTALL_LIBDIR} variable in the install invocation:

  install(TARGETS rct EXPORT rct LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR})

Cygwin Compile Error: SHM_DEST

Hi guys,

Ran into a compile error building today's latest from my cygwin machine:

/home/Brian/elisp/foreign/rtags/src/rct/rct/SharedMemory.cpp: In member function ‘bool     SharedMemory::init(key_t, int, SharedMemory::CreateMode)’:
/home/Brian/elisp/foreign/rtags/src/rct/rct/SharedMemory.cpp:44:29: error: ‘SHM_DEST’ was not declared in this scope
         ds.shm_perm.mode |= SHM_DEST;

Offending line:

#if !defined(OS_Darwin) && !defined(OS_FreeBSD)
      ds.shm_perm.mode |= SHM_DEST;
#endif 

It appears this isn't defined in my Cygwin
(CYGWIN_NT-6.1-WOW64 Kenobi 1.7.27(0.271/5/3) 2013-12-09 11:57 i686 Cygwin)

I added an extra preproc && !defined(__CYGWIN__) and it builds and operation looks OK, but I'm not sure what/if there are any consequences.

Thanks,
Brian

Compile error (cygwin+cmake) rct-config.h

Hi, after updating to latest rtags+rct I ran into this:

cd /home/Brian/elisp/foreign/rtags/build-test/src && /usr/bin/c++.exe   -Dshared_EXPORTS -    DHAVE_CXCOMPILATIONDATABASE -DCLANG_INCLUDEPATH=\"/usr/local/lib/clang/3.3/include/\" -DCLANG_VERSION_MAJOR=3 -DCLANG_VERSION_MINOR=3 -DOS_CYGWIN -DRTAGS_BIN=\"/home/Brian/elisp/foreign/rtags/build-test/bin/\" -fno-rtti -Wall -fstack-protector-all -Wstack-protector -std=gnu++0x -O3 -DNDEBUG -I/usr/local/include -I/home/Brian/elisp/foreign/rtags/src -I/home/Brian/elisp/foreign/rtags/src/rct/include -I/home/Brian/elisp/foreign/rtags/src/rct -I/home/Brian/elisp/foreign/rtags/build-test/src/rct/include/rct    -Wall -o CMakeFiles/shared.dir/CompileMessage.cpp.o -c /home/Brian/elisp/foreign/rtags/src/CompileMessage.cpp
In file included from /home/Brian/elisp/foreign/rtags/src/rct/rct/Log.h:7:0,
             from /home/Brian/elisp/foreign/rtags/src/rct/rct/Serializer.h:6,
             from /home/Brian/elisp/foreign/rtags/src/rct/rct/Message.h:4,
             from /home/Brian/elisp/foreign/rtags/src/RTagsMessage.h:19,
             from /home/Brian/elisp/foreign/rtags/src/CompileMessage.h:21,
             from /home/Brian/elisp/foreign/rtags/src/CompileMessage.cpp:16:
/home/Brian/elisp/foreign/rtags/src/rct/rct/Hash.h:6:28: fatal error: rct/rct-config.h: No such file or directory
 #include <rct/rct-config.h>

Looks like Hash.h includes <rct/rct-config.h> and a few other files (e.g. SocketServer.cpp) use <rct-config.h>

The options to the compiler above were -I.../build/src/rct/include/rct but not the parent directory.

Not compiling on PPC

When I tried to compile this on a power machine, I got the following error (using gcc 4.8.2):

/usr/lib64/ccache/c++   -DOS_Linux -DRCT_HAVE_ZLIB -Drct_EXPORTS -std=c++0x -fpic -fPIC -I/home/atf10khy/dev/rct -I/home/atf10khy/dev/rct/build/include/rct -I/home/atf10khy/dev/rct/build/include/rct/..    -o CMakeFiles/rct.dir/rct/Config.cpp.o -c /home/atf10khy/dev/rct/rct/Config.cpp
In file included from /home/atf10khy/dev/rct/rct/Value.h:6:0,
                 from /home/atf10khy/dev/rct/rct/Config.h:7,
                 from /home/atf10khy/dev/rct/rct/Config.cpp:1:
/home/atf10khy/dev/rct/rct/Serializer.h:208:20: error: redefinition of ‘struct FixedSize<long int>’
 DECLARE_NATIVE_TYPE(time_t);
                    ^
/home/atf10khy/dev/rct/rct/Serializer.h:202:20: error: previous definition of ‘struct FixedSize<long int>’
 DECLARE_NATIVE_TYPE(int64_t);
                    ^
/home/atf10khy/dev/rct/rct/Serializer.h:208:122: error: redefinition of ‘Serializer& operator<<(Serializer&, const T&) [with T = long int]’
 DECLARE_NATIVE_TYPE(time_t);
                                                                                                                          ^
/home/atf10khy/dev/rct/rct/Serializer.h:202:124: error: ‘Serializer& operator<<(Serializer&, const T&) [with T = long int]’ previously declared here
 DECLARE_NATIVE_TYPE(int64_t);
                                                                                                                            ^
/home/atf10khy/dev/rct/rct/Serializer.h:208:272: error: redefinition of ‘Deserializer& operator>>(Deserializer&, T&) [with T = long int]’
 DECLARE_NATIVE_TYPE(time_t);
                                                                                                                                                                                                                                                                                ^
/home/atf10khy/dev/rct/rct/Serializer.h:202:276: error: ‘Deserializer& operator>>(Deserializer&, T&) [with T = long int]’ previously declared here
 DECLARE_NATIVE_TYPE(int64_t);
                                                                                                                                                                                                                                                                                    ^

My workaround was to comment out the DECLARE_NATIVE_TYPE(time_t) line.

inotify attrib watcher causing unnecessary rebuilds

I'm using CMake and I have it configurefile() header files. Whenever I do anything that causes CMake to regenerate, it regenerates the configured header files to a temp file, then realizes that it's not different, but then changes the permissions on the header to make sure they are correct. This is causing an IN_ATTRIB notification, and because it's on a header, rdm ends up rebuilding even more than ninja would (using the ninja Generator in CMake).

See my workaround below:

In FileSystemWatcher_inotify.cpp:150

        } else if (event->mask & (IN_CLOSE_WRITE)) {
        // } else if (event->mask & (IN_ATTRIB|IN_CLOSE_WRITE)) {

Granted: CMake should probably not touch the generated file in any way unless it's is actually replacing the file I will report to them separately.

document how to build with clang when GCC < 4.8 is installed

I'm trying to build rtags with clang-3.4 installed from Ubuntu with GCC 4.6 installed, but I'm hitting this error:

android-main-2014-11-21 (release):~/t/rtags/build$ cmake ..
-- LLVM llvm-config found at: /usr/bin/llvm-config-3.4
-- Using Clang version 3.4 from /usr/lib/llvm-3.4/include/clang-c/
CMake Error at src/rct/rct.cmake:189 (message):
  C++11 support not detected.  rct requires a modern compiler, GCC >= 4.8 or
  Clang >= 3.2 should suffice
Call Stack (most recent call first):
  src/rct/CMakeLists.txt:2 (include)


-- Configuring incomplete, errors occurred!

Unfortunately I have no idea to build rtags with clang (e.g. override default g++). I'm not sure if installing gcc 4.8 is easy on my older Ubuntu. It's probably just a cmake config step away.

This would be nice to document in the README.

cygwin threadpool compile errors

Hi guys,

Thanks for taking the time to go through those changes and put together a solution for Cygwin.

I pulled a fresh copy of rtags/rct and tried to build using master, hitting compile errors in ThreadPool.cpp.

$ uname -a
CYGWIN_NT-6.1-WOW64 Kenobi 1.7.11(0.260/5/3) 2012-02-24 14:05 i686 Cygwin

$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/home/Brian/build/gcc-4_8/libexec/gcc/i686-pc-cygwin/4.8.0/lto-wrapper.exe
Target: i686-pc-cygwin
Configured with: ../gcc-4.8.0/configure --prefix=/home/Brian/build/gcc-4_8 --enable-languages=c,c++ --enable-graphite --disable-symvers --enable-libssp --enable-threads=posix --with-arch=i686 --enable-bootstrap --enable-static --enable-shared --enable-shared-libgcc --disable-__cxa_atexit --with-gnu-ld --with-gnu-as --with-dwarf2 --disable-sjlj-exceptions --enable-libgomp --enable-lto --with-tune=generic
Thread model: posix
gcc version 4.8.0 (GCC)

[ 3%] Building CXX object src/rct/CMakeFiles/rct.dir/rct/ThreadPool.cpp.o
cd /home/Brian/code/fresh-rtags/build/src/rct && /home/Brian/build/gcc-4_8/bin/c++.exe -DHAVE_CXCOMPILATIONDATABASE -DOS_CYGWIN -DOS_CYGWIN -std=gnu++0x -O3 -DNDEBUG -I/usr/local/include -I/home/Brian/code/fresh-rtags/src/rct -I/home/Brian/code/fresh-rtags/build/src/rct/include/rct -o CMakeFiles/rct.dir/rct/ThreadPool.cpp.o -c /home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp: In static member function ‘static int ThreadPool::idealThreadCount()’:
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:215:44: error: ‘GetLogicalProcessorInformation’ was not declared in this scope
GetLogicalProcessorInformation(0, &size);
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:221:5: error: ‘PSYSTEM_LOGICAL_PROCESSOR_INFORMATION’ was not declared in this scope
PSYSTEM_LOGICAL_PROCESSOR_INFORMATION procs = new SYSTEM_LOGICAL_PROCESSOR_INFORMATION[size];
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:221:43: error: expected ‘;’ before ‘procs’
PSYSTEM_LOGICAL_PROCESSOR_INFORMATION procs = new SYSTEM_LOGICAL_PROCESSOR_INFORMATION[size];
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:222:41: error: ‘procs’ was not declared in this scope
if (!GetLogicalProcessorInformation(procs, &size)) {
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:223:18: error: type ‘’ argument given to ‘delete’, expected pointer
delete[] procs;
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:228:40: error: ‘SYSTEM_LOGICAL_PROCESSOR_INFORMATION’ was not declared in this scope
const size_t elems = size / sizeof(SYSTEM_LOGICAL_PROCESSOR_INFORMATION);
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:230:13: error: ‘procs’ was not declared in this scope
if (procs[i].Relationship == RelationProcessorCore) {
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:230:38: error: ‘RelationProcessorCore’ was not declared in this scope
if (procs[i].Relationship == RelationProcessorCore) {
^
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:243:14: error: ‘procs’ was not declared in this scope
delete[] procs;
^
In file included from /usr/include/w32api/windows.h:48:0,
from /home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:15:
/home/Brian/code/fresh-rtags/src/rct/rct/ThreadPool.cpp:244:17: error: expected unqualified-id before ‘(’ token
return std::max(numThreads, numCores);
^
src/rct/CMakeFiles/rct.dir/build.make:445: recipe for target src/rct/CMakeFiles/rct.dir/rct/ThreadPool.cpp.o' failed make[2]: *** [src/rct/CMakeFiles/rct.dir/rct/ThreadPool.cpp.o] Error 1 make[2]: Targetsrc/rct/CMakeFiles/rct.dir/build' not remade because of errors.
make[2]: Leaving directory /home/Brian/code/fresh-rtags/build' CMakeFiles/Makefile2:379: recipe for targetsrc/rct/CMakeFiles/rct.dir/all' failed
make[1]: *** [src/rct/CMakeFiles/rct.dir/all] Error 2

Can't compile on Ubuntu 22.04.1 LTS

When trying to build (simple cmake .) the current master I get this on Ubuntu:

  Target "rct" has policy CMP0022 enabled, but also has old-style           
  LINK_INTERFACE_LIBRARIES properties populated, but it was exported without
  the EXPORT_LINK_INTERFACE_LIBRARIES to export the old-style properties    

RCT ungracefully fails to load projects from cache

Behavior:
When starting RDM, RCT (via libc) will throw an exception if the cache is invalid (I deleted my ~/.cache/rtags directory to fix without thinking about digging further into exactly how it was invalid, my apologies!).

Expected Behavior:
RDM should fail gracefully if it can't load the cache, and provide a better error message regarding why it's failing.

Troubleshooting:
I was able to grab a backtrace as the original error message didn't indicate exactly why RDM was failing (I updated recently and initially thought it was a glibc incompatibility). Here is the trace:

terminate called after throwing an instance of 'std::length_error'                                                                                                                                
  what():  basic_string::_M_create                                                                                                                                                                
                                                                                                                                                                                                  
Program received signal SIGABRT, Aborted.                                                                                                                                                         
0x00007ffff7517755 in raise () from /usr/lib/libc.so.6                                                                                                                                            
(gdb) bt                                                                                                                                                                                          
#0  0x00007ffff7517755 in raise () from /usr/lib/libc.so.6                                                                                                                                        
#1  0x00007ffff7502851 in abort () from /usr/lib/libc.so.6                                                                                                                                        
#2  0x00007ffff7db381f in __gnu_cxx::__verbose_terminate_handler () at /build/gcc/src/gcc/libstdc++-v3/libsupc++/vterminate.cc:95                                                                 
#3  0x00007ffff7dc030a in __cxxabiv1::__terminate (handler=<optimized out>) at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:47                                                       
#4  0x00007ffff7dc0367 in std::terminate () at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_terminate.cc:57                                                                                       
#5  0x00007ffff7dc05bd in __cxxabiv1::__cxa_throw (obj=obj@entry=0x555555e899e0, tinfo=0x7ffff7ef8470 <typeinfo for std::length_error>, dest=0x7ffff7dd6760 <std::length_error::~length_error()>) 
    at /build/gcc/src/gcc/libstdc++-v3/libsupc++/eh_throw.cc:95                                                                                                                                   
#6  0x00007ffff7db63a3 in std::__throw_length_error (__s=__s@entry=0x7ffff7eb30c9 "basic_string::_M_create") at /build/gcc/src/gcc/libstdc++-v3/src/c++11/functexcept.cc:78                       
#7  0x00007ffff7e5ffde in std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_M_create (this=<optimized out>, __capacity=@0x7fffffffb858: 18446744071984111808,     
    __old_capacity=__old_capacity@entry=0) at /build/gcc/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/include/ext/new_allocator.h:102                                                           
#8  0x00007ffff7e6007d in std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_M_construct (this=this@entry=0x7fffffffb880, __n=<optimized out>,                     
    __n@entry=18446744071984111808, __c=__c@entry=0 '\000') at /build/gcc/src/gcc-build/x86_64-pc-linux-gnu/libstdc++-v3/include/bits/char_traits.h:300           
#9  0x000055555573b6f9 in std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::basic_string (__a=..., __c=0 '\000', __n=18446744071984111808, this=0x7fffffffb880)
    at /usr/include/c++/9.1.0/ext/new_allocator.h:83                                                                                                                                              
#10 String::String (fillChar=0 '\000', len=18446744071984111808, this=0x7fffffffb880) at /home/{scrubbed}/projects/rtags/src/rct/rct/String.h:44                      
#11 Rct::readAll (f=f@entry=0x555555e89e30, max=max@entry=-1) at /home/{scrubbed}/projects/rtags/src/rct/rct/Rct.cpp:136                      
#12 0x0000555555738189 in Path::readAll (this=this@entry=0x7fffffffbaa0, max=max@entry=18446744073709551615) at /home/{scrubbed}/projects/rtags/src/rct/rct/Path.cpp:696
#13 0x00005555556ff748 in DataFile::open (this=this@entry=0x7fffffffba80, mode=mode@entry=DataFile::Read) at /home/{scrubbed}/projects/rtags/src/rct/rct/DataFile.h:75
#14 0x00005555556f239e in Project::readSources (path=..., data=..., err=0x7fffffffbc00) at /home/{scrubbed}/projects/rtags/src/Project.cpp:310
#15 0x00005555556f6315 in Project::init (this=this@entry=0x555555e890a0) at /home/{scrubbed}/projects/rtags/src/Project.cpp:349           
#16 0x00005555555fdb2b in Server::addProject (this=0x555555801e30, path=...) at /home/{scrubbed}/projects/rtags/src/Server.cpp:342
#17 0x00005555555fedb3 in Server::load (this=0x555555801e30) at /home/{scrubbed}/projects/rtags/src/Server.cpp:2207
#18 0x00005555555ffc50 in Server::init (this=this@entry=0x555555801e30, options=...) at /home/{scrubbed}/projects/rtags/src/Server.cpp:210
#19 0x00005555555c83bc in main (argc=<optimized out>, argv=<optimized out>) at /home/{scrubbed}/projects/rtags/src/rdm.cpp:869
(gdb) 

For posterity, the original output I received when starting the daemon was:

[{scrubbed}@archlinux bin]$ ./rdm                                                                                                                                                              Running with 12 jobs, using args: -ferror-limit=50 -Wall -fspell-checking -Wno-unknown-warning-option                                                                                             
Includepaths: "-isystem" /usr/lib/clang/8.0.0/include/                                                                                                                                            
terminate called after throwing an instance of 'std::length_error'                                                                                                                                
  what():  basic_string::_M_create                                                                                                                                                                
Caught signal 6                                                                                                                                                                                   
./rdm(+0x7655d)[0x562f6ba5955d]                                                                                                                                                                   
/usr/lib/libc.so.6(+0x3a7e0)[0x7fdb206527e0]                                                                                                                                                      
/usr/lib/libc.so.6(gsignal+0x145)[0x7fdb20652755]                                                                                                                                                 
/usr/lib/libc.so.6(abort+0x125)[0x7fdb2063d851]                                                                                                                                                   
/usr/lib/libstdc++.so.6(+0x9581f)[0x7fdb20eee81f]                                                                                                                                                 
/usr/lib/libstdc++.so.6(+0xa230a)[0x7fdb20efb30a]                                                                                                                                                 
/usr/lib/libstdc++.so.6(+0xa2367)[0x7fdb20efb367]                                                                                                                                                 
/usr/lib/libstdc++.so.6(+0xa25bd)[0x7fdb20efb5bd]                                                                                                                                                 
/usr/lib/libstdc++.so.6(_ZSt20__throw_length_errorPKc+0x45)[0x7fdb20ef13a3]                                                                                                                       
/usr/lib/libstdc++.so.6(+0x141fde)[0x7fdb20f9afde]                                                                                                                                                
/usr/lib/libstdc++.so.6(_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_M_constructEmc+0x5d)[0x7fdb20f9b07d]                                                                              
./rdm(_ZN3Rct7readAllEP8_IO_FILEi+0x79)[0x562f6bbca6f9]                                                                                                                                           
./rdm(_ZNK4Path7readAllEm+0x49)[0x562f6bbc7189]                                                                                                                                                   
./rdm(_ZN8DataFile4openENS_4ModeE+0x48)[0x562f6bb8e748]                                                                                                                                           
./rdm(_ZN7Project11readSourcesERK4PathR14IndexParseDataP6String+0xde [0x562f6bb8139e]                                                                                                             
./rdm(_ZN7Project4initEv+0x4f5)[0x562f6bb85315]                                                                                                                                                   
./rdm(_ZN6Server10addProjectERK4Path+0x25b)[0x562f6ba8cb2b]                                                                                                                                       
./rdm(_ZN6Server4loadEv+0x10b3)[0x562f6ba8ddb3]                                                                                                                                                   
./rdm(_ZN6Server4initERKNS_7OptionsE+0xcc0)[0x562f6ba8ec50]                                                                                                                                       
./rdm(main+0x223c)[0x562f6ba573bc]                                                                                                                                                                
/usr/lib/libc.so.6(__libc_start_main+0xf3)[0x7fdb2063eee3]                                                                                                                                        
./rdm(_start+0x2e)[0x562f6ba5943e]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.