Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-17153

Memory leak when web hook compilation fails

XMLWordPrintable

    • Sprint 60 (Jan 2020)
    • 0.5

      Create web hook that is not possible to compile, press test and notice memory leak due to error message not being cleaned

      Leaks detected:
      ==61465== HEAP SUMMARY:
      ==61465==     in use at exit: 337,947 bytes in 5,198 blocks
      ==61465==   total heap usage: 105,926 allocs, 100,728 frees, 9,658,090 bytes allocated
      ==61465== 
      ==61465== 276 bytes in 6 blocks are definitely lost in loss record 605 of 705
      ==61465==    at 0x483880B: malloc (vg_replace_malloc.c:309)
      ==61465==    by 0x588C6CE: strdup (in /usr/lib64/libc-2.29.so)
      ==61465==    by 0x5C8A96: zbx_strdup2 (misc.c:577)
      ==61465==    by 0x492F00: zbx_es_compile (embed.c:379)
      ==61465==    by 0x4251CB: zbx_am_update_webhook (alert_manager.c:368)
      ==61465==    by 0x425AB3: am_update_mediatype (alert_manager.c:446)
      ==61465==    by 0x429338: am_process_external_alert_request (alert_manager.c:1889)
      ==61465==    by 0x429C8E: alert_manager_thread (alert_manager.c:2062)
      ==61465==    by 0x5C0E31: zbx_thread_start (threads.c:136)
      ==61465==    by 0x424902: MAIN_ZABBIX_ENTRY (server.c:1211)
      ==61465==    by 0x5B1784: daemon_start (daemon.c:387)
      ==61465==    by 0x423AA2: main (server.c:895)
      ==61465== 
      ==61465== LEAK SUMMARY:
      ==61465==    definitely lost: 276 bytes in 6 blocks
      ==61465==    indirectly lost: 0 bytes in 0 blocks
      ==61465==      possibly lost: 0 bytes in 0 blocks
      ==61465==    still reachable: 337,439 bytes in 5,190 blocks
      ==61465==                       of which reachable via heuristic:
      ==61465==                         length64           : 107,261 bytes in 1,209 blocks
      ==61465==         suppressed: 232 bytes in 2 blocks
      ==61465== Reachable blocks (those to which a pointer was found) are not shown.
      ==61465== To see them, rerun with: --leak-check=full --show-leak-kinds=a
      

            mabele Martins Abele
            vso Vladislavs Sokurenko
            Team A
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: