Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 7.8.6
    • Component/s: Plugins
    • Labels:
      None

      Description

      Running mysqlemebd.cpp under valgrind gives several leaks with the following callstack:

       

      ==29381== 67,249 (1,232 direct, 66,017 indirect) bytes in 1 blocks are definitely lost in loss record 456 of 460
      ==29381==    at 0x483B583: operator new[](unsigned long) (in /usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==29381==    by 0x4FF95511: mysqlembed::MySQLBindingArray::init(unsigned int) (mysqlembed.cpp:558)
      ==29381==    by 0x4FF959CF: mysqlembed::MySQLBindingArray::bindResults(MYSQL_RES*) (mysqlembed.cpp:576)
      ==29381==    by 0x4FF97051: mysqlembed::MySQLPreparedStatement::execute() (mysqlembed.cpp:699)
      ==29381==    by 0x4FF9B5E2: mysqlembed::MySQLEmbedFunctionContext::lazyExecute() (mysqlembed.cpp:1683)
      ==29381==    by 0x4FF99D8C: mysqlembed::MySQLEmbedFunctionContext::getRowResult(IEngineRowAllocator*) (mysqlembed.cpp:1477)
      ==29381==    by 0x5782AFB8: user14(ICodeContext*, IEngineRowAllocator*) (W20200409-151201_1.cpp:321)
      ==29381==    by 0x5782F6E7: cAc16::getRow(ARowBuilder&, unsigned long long) (W20200409-151201_1.cpp:301)
      ==29381==    by 0x4C57D12: CRoxieServerStrandedInlineTableActivity::InlineTableSimpleProcessor::nextRow() (ccdserver.cpp:6058)
      ==29381==    by 0x4CE713C: CRoxieServerRemoteResultActivity::onExecute() (ccdserver.cpp:21713)
      ==29381==    by 0x4C3B6C8: CRoxieServerInternalSinkActivity::execute(unsigned int, unsigned char const*) (ccdserver.cpp:2876)
      ==29381==    by 0x4D2C259: CActivityGraph::doExecute(unsigned int, unsigned char const*) (ccdserver.cpp:27641)
      ==29381==    by 0x4D2C08F: CActivityGraph::execute() (ccdserver.cpp:27609)
      ==29381==    by 0x4BD9C23: CRoxieContextBase::runGraph() (ccdcontext.cpp:1570)
      ==29381==    by 0x4BD9F84: CRoxieContextBase::executeGraph(char const*, bool, unsigned int, void const*) (ccdcontext.cpp:1603)
      ==29381==    by 0x578285A0: MyEclProcess::perform(IGlobalCodeContext*, unsigned int) (W20200409-151201.cpp:273)
      ==29381==    by 0x6305F11: WorkflowMachine::performItem(unsigned int, unsigned int) (workflow.cpp:961)
      ==29381==    by 0x6304A82: WorkflowMachine::doExecuteItem(IRuntimeWorkflowItem&, unsigned int) (workflow.cpp:818)
      ==29381==    by 0x6303F99: WorkflowMachine::executeItem(unsigned int, unsigned int) (workflow.cpp:716)
      ==29381==    by 0x6303801: WorkflowMachine::perform(IGlobalCodeContext*, IEclProcess*) (workflow.cpp:646)
      ==29381==    by 0x4BE942C: CRoxieServerContext::process() (ccdcontext.cpp:3052)
      ==29381==    by 0x4DB946D: RoxieWorkUnitWorker::doMain(IConstWorkUnit*, IQueryFactory*, StringContextLogger&) (ccdlistener.cpp:1263)
      ==29381==    by 0x4DB8A12: RoxieWorkUnitWorker::threadmain() (ccdlistener.cpp:1211)
      ==29381==    by 0x706D2A0: CPooledThreadWrapper::run() (jthread.cpp:932)
      ==29381==    by 0x7067AFC: Thread::begin() (jthread.cpp:291)
      
      

      mysqlembed.cpp(558) is the following:

                  bindinfo = new MYSQL_BIND [columns];
      
      

      I think it is because bindResults calls init - probably each time a statement is executed.

      Richard Chapman

       

        Attachments

          Activity

            People

            • Assignee:
              ghalliday Gavin Halliday
              Reporter:
              ghalliday Gavin Halliday
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: