瀏覽代碼

fix LOCK file deletion to prevent crash on windows

master
Sanjay Ghemawat 12 年之前
父節點
當前提交
583f1499c0
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. +1
    -1
      db/db_impl.cc

+ 1
- 1
db/db_impl.cc 查看文件

@ -1427,7 +1427,7 @@ Status DestroyDB(const std::string& dbname, const Options& options) {
FileType type;
for (size_t i = 0; i < filenames.size(); i++) {
if (ParseFileName(filenames[i], &number, &type) &&
filenames[i] != lockname) { // Lock file will be deleted at end
type != kDBLockFile) { // Lock file will be deleted at end
Status del = env->DeleteFile(dbname + "/" + filenames[i]);
if (result.ok() && !del.ok()) {
result = del;

Loading…
取消
儲存