dropbox / json11

A tiny JSON library for C++11.
MIT License
2.54k stars 613 forks source link

json11::Json::dump throws exception dumping empty map in gdb #100

Open krszalay opened 7 years ago

krszalay commented 7 years ago

json11 raises a "pure virtual function call" exception when trying to dump the following json: {"params": {}, "method": "ping", "id": 1}

this only happens in gdb

j4cbo commented 7 years ago

Can you post a minimal test case? This could be the result of other memory corruption.

artwyman commented 7 years ago

I think this needs more context to be acted upon. Does dumping mean calling Json::dump() normally or something specific to the debugger? Does calling it normally within the same program work? Is it possible that the dump() method simply isn't compiled into the program because it's unused or something like that?

An example plus repro steps would be good. A stack trace would be useful too.