Closed brianonn closed 7 years ago
Wow! Great. Thanks! @brianonn
Actually, sqlite3_close could be called harmlessly on a NULL pointer. https://sqlite.org/c3ref/close.html
@ruben2020 Good to know. NULL pointers are ok then, so you can save an if().
Thanks for making your tool available. I decided to give it a try when I needed case-insensitive lookups for just a few symbols. cscope wasn't giving me that. With cscope, your only choice is to make the the entire database case insensitive (or not). Your tool handles this use case better, and it's fast with the sqlite3 db. I like the function call graphs and class inheritance graphs for looking at new code too.
cqmakedb crashed with a segmentation violation at the very end of it's run.
Class ctagread has sqlbase for its base class, and the db is closed inside of the ctagread class. The inherited member m_db is used here as the argument to the library function sqlite3_close(). When the ctagread instance goes out of scope, the base class destructor is eventually called and the base class calls sqlite3_close() one more time. In my case, it was called with an invalid pointer, causing the segmentation violation. I suspect this is the same bug described in #39