Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 1e31f5f307c887a616fd1a1f7cc8df31cb6af9c8
Ticket: 05d9a601e45db736729ed5b7a260dd675f245bb4
Memory leak with creating and destroying threads from C
User & Date: rkeene on 2016-04-04 17:22:52
Changes

  1. closer changed to: "nobody"
  2. icomment:
    No change with Tcl 8.6.5.
    
    I did update the source to print the version number (via Tcl_GetVersion()), exit early if pthread_create() fails, and call Tcl_FindExecutable(argv[0]) -- updated source attached.
    
    
    
    ++ x86_64-generic-linux-gnu-gcc -std=gnu11 -o test-leak test-leak.c -Wall -pthread -ltcl8.6 -I./tcl8.6.5/INST/include -L./tcl8.6.5/INST/lib -Wl,-R,/home/rkeene/devel/appfs/build/tcl8.6.5/INST/lib '-DPACKAGE_NAME="tcl"' '-DPACKAGE_TARNAME="tcl"' '-DPACKAGE_VERSION="8.6"' '-DPACKAGE_STRING="tcl 8.6"' '-DPACKAGE_BUGREPORT=""' -DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 -DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 -DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_SYS_PARAM_H=1 -DUSE_THREAD_ALLOC=1 -D_REENTRANT=1 -D_THREAD_SAFE=1 -DHAVE_PTHREAD_ATTR_SETSTACKSIZE=1 -DHAVE_PTHREAD_ATFORK=1 -DTCL_THREADS=1 '-DTCL_CFGVAL_ENCODING="iso8859-1"' -DHAVE_ZLIB=1 '-DMODULE_SCOPE=extern __attribute__((__visibility__("hidden")))' -DHAVE_HIDDEN=1 -DHAVE_CAST_TO_UNION=1 '-DTCL_SHLIB_EXT=".so"' -DNDEBUG=1 -DTCL_CFG_OPTIMIZED=1 -DTCL_TOMMATH=1 -DMP_PREC=4 -D_LARGEFILE64_SOURCE=1 -DTCL_WIDE_INT_IS_LONG=1 -DHAVE_GETCWD=1 -DHAVE_MKSTEMP=1 -DHAVE_OPENDIR=1 -DHAVE_STRTOL=1 -DHAVE_WAITPID=1 -DHAVE_GETNAMEINFO=1 -DHAVE_GETADDRINFO=1 -DHAVE_FREEADDRINFO=1 -DHAVE_GAI_STRERROR=1 -DHAVE_STRUCT_ADDRINFO=1 -DHAVE_STRUCT_IN6_ADDR=1 -DHAVE_STRUCT_SOCKADDR_IN6=1 -DHAVE_STRUCT_SOCKADDR_STORAGE=1 -DHAVE_GETPWUID_R_5=1 -DHAVE_GETPWUID_R=1 -DHAVE_GETPWNAM_R_5=1 -DHAVE_GETPWNAM_R=1 -DHAVE_GETGRGID_R_5=1 -DHAVE_GETGRGID_R=1 -DHAVE_GETGRNAM_R_5=1 -DHAVE_GETGRNAM_R=1 -DHAVE_GETHOSTBYNAME_R_6=1 -DHAVE_GETHOSTBYNAME_R=1 -DHAVE_GETHOSTBYADDR_R_8=1 -DHAVE_GETHOSTBYADDR_R=1 -DHAVE_TERMIOS_H=1 -DHAVE_SYS_IOCTL_H=1 -DHAVE_SYS_TIME_H=1 -DTIME_WITH_SYS_TIME=1 -DHAVE_GMTIME_R=1 -DHAVE_LOCALTIME_R=1 -DHAVE_MKTIME=1 -DHAVE_TM_GMTOFF=1 -DHAVE_TIMEZONE_VAR=1 -DHAVE_STRUCT_STAT_ST_BLOCKS=1 -DHAVE_STRUCT_STAT_ST_BLKSIZE=1 -DHAVE_BLKCNT_T=1 -DHAVE_INTPTR_T=1 -DHAVE_UINTPTR_T=1 -DHAVE_SIGNED_CHAR=1 -DHAVE_LANGINFO=1 -DHAVE_MKSTEMPS=1 -DHAVE_FTS=1 -DHAVE_SYS_IOCTL_H=1 -DTCL_UNLOAD_DLLS=1 -DHAVE_CPUID=1
    Testing Tcl version 8.6.5
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 0, Interp Count: 0
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 1, Interp Count: 1
    Thread Count: 0, Interp Count: 0
    Thread Count: 0, Interp Count: 0
    error: pthread_create() failed, exiting.
    
  3. login: "rkeene"
  4. mimetype: "text/plain"
  5. resolution changed to: "None"
  6. status changed to: "Open"