gvansickle / ucg

UniversalCodeGrep (ucg) is an extremely fast grep-like tool specialized for searching large bodies of source code.

Home Page:https://gvansickle.github.io/ucg/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

segfault in microstring::length()

gvansickle opened this issue · comments

string.hpp lines 93/94:

        auto tmp = m_storage;
        auto ptr = reinterpret_cast<const char *>(tmp);

The tmp needs an & in front of it.

Also, constructor not working correctly for strings less than 3 chars long.