I've added an assertlockheld(cs_main) in coins.cpp, and I get the following stack trace when trying to reindex:
Assertion failed: lock cs_main not held in coins.cpp:194; locks held:
[#3](/bitcoin-bitcoin/3/) 0x54beb616 in AssertLockHeldInternal (pszName=0x0, pszFile=0x1 <error: Cannot access memory at address 0x1>, nLine=nLine@entry=194, cs=0x54e08b48 <cs_main>) at sync.cpp:149
[#4](/bitcoin-bitcoin/4/) 0x54bb52ec in CCoinsViewCache::Flush (this=0x54e7b9f8) at coins.cpp:194
[#5](/bitcoin-bitcoin/5/) 0x54afee4c in FlushStateToDisk (state=..., mode=mode@entry=FLUSH_STATE_PERIODIC) at main.cpp:1805
[#6](/bitcoin-bitcoin/6/) 0x54b069d2 in ActivateBestChain (state=..., pblock=pblock@entry=0x2f9fed08) at main.cpp:2127
[#7](/bitcoin-bitcoin/7/) 0x54b06ef2 in ProcessNewBlock (state=..., pfrom=pfrom@entry=0x0, pblock=pblock@entry=0x2f9fed08, dbp=dbp@entry=0x2f9feddc) at main.cpp:2579
[#8](/bitcoin-bitcoin/8/) 0x54b0739e in LoadExternalBlockFile (fileIn=fileIn@entry=0x2fa007a8, dbp=dbp@entry=0x2f9feddc) at main.cpp:3191
[#9](/bitcoin-bitcoin/9/) 0x54ad574c in ThreadImport (vImportFiles=std::vector of length 0, capacity 0) at init.cpp:417