diff --git a/source/libs/stream/src/streamState.c b/source/libs/stream/src/streamState.c index 2db4f2491b17d58c2cdeb35871adb6ae12bf97da..1ab701435748c0a0286f76ef5833de2b11665575 100644 --- a/source/libs/stream/src/streamState.c +++ b/source/libs/stream/src/streamState.c @@ -669,7 +669,7 @@ void streamStateFreeCur(SStreamStateCur* pCur) { } qDebug("streamStateFreeCur"); rocksdb_iter_destroy(pCur->iter); - rocksdb_release_snapshot(pCur->db, pCur->snapshot); + if (pCur->snapshot) rocksdb_release_snapshot(pCur->db, pCur->snapshot); rocksdb_readoptions_destroy(pCur->readOpt); tdbTbcClose(pCur->pCur);