D 2013-07-17T04:15:54.177 J foundin 3.7.17 J icomment
\r\nIn\sthe\ssrc/vtab.c
\sand\sthe\ssqlite3VtabSync
\sfunction,\spVtab->zErrMsg
\sis\sfreed\swithout\sthen\sbeing\szeroed.\s\sThis\sleads\sto\sa\sdouble-free\serror\scondition\swhen\spVtab->zErrMsg
\sis\slater\sexamined,\sfound\snon-zero\sand\sfreed\s(again).\r\n
\r\nThe\ssimplest\sway\sto\sreproduce\sthe\sproblem\sis\sto\screate\sa\svirtual\stable\simplementation\sthat\simplements\sxSync
.\s\sIn\sxSync
,\sset\spVtab->zErrMsg
\sto\san\sallocated\sstring\sand\sreturn\san\serror\sresult.\s\sAt\sthe\snext\scallback\sopportunity\s(mine\swas\sin\sxRollback
),\spVtab->zErrMsg
\swill\sstill\sbe\sset,\swhen\sit\sshould\sbe\szero.\r\n