Skip to content
Snippets Groups Projects
Select Git revision
  • dd_area_choosers_common_refactor
  • master default protected
  • dailybuild_linux-x64
  • dailybuild_win32
  • sqlite
  • rip_abstraction
  • dailybuild_macos-armv8
  • dd_file_lister_filanem_in_desc_color
  • mode7
  • dd_msg_reader_are_you_there_warning_improvement
  • c23-playing
  • syncterm-1.3
  • syncterm-1.2
  • test-build
  • hide_remote_connection_with_telgate
  • 638-can-t-control-c-during-a-file-search
  • add_body_to_pager_email
  • mingw32-build
  • cryptlib-3.4.7
  • ree/mastermind
  • sbbs320d
  • syncterm-1.6
  • syncterm-1.5
  • syncterm-1.4
  • sbbs320b
  • syncterm-1.3
  • syncterm-1.2
  • syncterm-1.2rc6
  • syncterm-1.2rc5
  • push
  • syncterm-1.2rc4
  • syncterm-1.2rc2
  • syncterm-1.2rc1
  • sbbs319b
  • sbbs318b
  • goodbuild_linux-x64_Sep-01-2020
  • goodbuild_win32_Sep-01-2020
  • goodbuild_linux-x64_Aug-31-2020
  • goodbuild_win32_Aug-31-2020
  • goodbuild_win32_Aug-30-2020
40 results

ini_file.c

  • Rob Swindell's avatar
    7d3bcf18
    Fix memory leak in iniFreeParsedSections(), wasn't freeing the list member · 7d3bcf18
    Rob Swindell authored
    The 'list' member was allocated by iniParseSections() but never freed.
    
    Caught be Nelgin's recent valgrind report, e.g.:
    
    ==2725235== 56 bytes in 1 blocks are indirectly lost in loss record 82 of 191
    ==2725235==    at 0x484DCD3: realloc (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so)
    ==2725235==    by 0x4FA351C: strListAnnex (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x4F9ADDE: iniParseSections (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x49F1F0A: read_chat_cfg (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x49E8BF1: load_cfg (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x5C14C75: ftp_server (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libftpsrvr.so)
    ==2725235==    by 0x5D5AB42: start_thread (pthread_create.c:442)
    ==2725235==    by 0x5DEBBB3: clone (clone.S:100)
    7d3bcf18
    History
    Fix memory leak in iniFreeParsedSections(), wasn't freeing the list member
    Rob Swindell authored
    The 'list' member was allocated by iniParseSections() but never freed.
    
    Caught be Nelgin's recent valgrind report, e.g.:
    
    ==2725235== 56 bytes in 1 blocks are indirectly lost in loss record 82 of 191
    ==2725235==    at 0x484DCD3: realloc (in /usr/libexec/valgrind/vgpreload_memcheck-amd64-linux.so)
    ==2725235==    by 0x4FA351C: strListAnnex (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x4F9ADDE: iniParseSections (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x49F1F0A: read_chat_cfg (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x49E8BF1: load_cfg (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libsbbs.so)
    ==2725235==    by 0x5C14C75: ftp_server (in /home/bbs/sbbs/repo/src/sbbs3/gcc.linux.x64.lib.release/libftpsrvr.so)
    ==2725235==    by 0x5D5AB42: start_thread (pthread_create.c:442)
    ==2725235==    by 0x5DEBBB3: clone (clone.S:100)