Tk Source Code

View Ticket
Login
Ticket UUID: 218561bf8dfd3c3e5565c177abf109b915a16797
Title: Tk8.6.5 - Starkit binary under OSX 10.9.5 / OSX 10.11.3 crashes when resizing main window while dragging with the mouse
Type: Bug Version: Tk8.6.5
Submitter: anonymous Created on: 2016-03-17 21:07:05
Subsystem: 66. Aqua Window Operations Assigned To: kevin_walzer
Priority: 5 Medium Severity: Important
Status: Open Last Modified: 2016-04-11 10:42:14
Resolution: None Closed By: nobody
    Closed on:
Description:
Managed to crash a tk application running under OS X:

Starkit binary under OSX 10.9.5 / OSX 10.11.3 crashes when resizing main window while dragging with the mouse! Increasing the main window size works, when dragging the mouse so that the window gets smaller than it's initial size, the whole program crashes immediately.

Remark: under WIN there is no problem with the same source code.

The following kit binaries where tested under OSX:

# Makefile ---
# -------------------------------------------------------------------------
#   Purpose:
#       Create (*)starkit and application binaries
#       for unix and windows. This makefile might be used to
#       "cross compile" binaries for any target OS.
# 
#   Copyright(c) 2008,  Johann Oberdorfer
#                       mail-to: johann.oberdorfer [at] gmail.com
# -------------------------------------------------------------------------
# This source file is distributed under the BSD license.

# main entry point:
TCLROOT=/Volumes/share-01/JOB_Apps/tclkit

# binaries from sourceforge kbs.tcl ...
WIN_KIT=$(TCLROOT)/WindowsNT_kbsvq8.6-gui.exe

# SourceForge kbs.tcl 0.4.8 tcl/tk 8.6.5 currently crashes when attempting to re-size
# the main window frame -> making the window smaller
# OSX_KIT=$(TCLROOT)/Darwin_kbsvq8.6-gui

# http://tclkits.rkeene.org/fossil/wiki/Downloads, crashes as well !?
# OSX_KIT=$(TCLROOT)/tclkit-8.6.3-macosx10.5-ix86+x86_64

# after all, previous version, kbs.tcl 0.4.5 tcl/tk 8.6.1  works fine  ...
OSX_KIT=$(TCLROOT)/Darwin_kbsvq8-2.6-gui


# the sdx utility:
SDXUTIL=$(TCLROOT)/sdx.kit
...

Could manage to eliminate the problem, by moving back to previous Tcl/Tk 8.6.1 version.

Maybe the problem is already known ?
Would it help to provide some test code to reproduce the problem?

With best regards,
  Johann
User Comments: kevin_walzer added on 2016-04-11 10:41:05:
I lack time to debug starkits, but if you can provide a sample script for standard Wish that reproduces the problem, I will take a look.

anonymous (claiming to be auriocus) added on 2016-04-11 07:42:43:
I can confirm that it sometimes crashes, especially if the border is moved vigorously. I cannot make it crash anytime, e.g. if just tkcon is loaded, it doesn't crash. If there are some native widgets and I start to vigorously resize the window, errors like this appear:

Apr 11 09:41:34  wish86[28459] <Error>: CGImageCreate: invalid image bits/pixel or bytes/row.

which finally lead to a segfault. (8.6.5, El Capitan 10.11.4)