Ticket #10374: 0003-Fix-mismatching-allocation-and-deallocation.patch

File 0003-Fix-mismatching-allocation-and-deallocation.patch, 966 bytes (added by mt, 10 years ago)

Patch

  • src/add-ons/index_server/fulltext/CLuceneDataBase.cpp

    From 3eb998434a3bc17da02b8b834a67d23583530555 Mon Sep 17 00:00:00 2001
    From: Murai Takashi <tmurai01@gmail.com>
    Date: Sat, 4 Jan 2014 09:05:23 +0900
    Subject: [PATCH 3/3] Fix mismatching allocation and deallocation
    
    ---
     .../index_server/fulltext/CLuceneDataBase.cpp      |    4 ++--
     1 file changed, 2 insertions(+), 2 deletions(-)
    
    diff --git a/src/add-ons/index_server/fulltext/CLuceneDataBase.cpp b/src/add-ons/index_server/fulltext/CLuceneDataBase.cpp
    index 9862595..e60db9c 100644
    a b CLuceneWriteDataBase::_RemoveDocuments(std::vector<entry_ref>& docs)  
    210210                break;
    211211            }
    212212        }
    213         delete wPath;
     213        delete[] wPath;
    214214
    215215        if (!status)
    216216            break;
    CLuceneWriteDataBase::_IndexDocument(const entry_ref& ref)  
    296296
    297297    if (!status)
    298298        delete document;
    299     delete wPath;
     299    delete[] wPath;
    300300    return status;
    301301}