Created
December 24, 2010 05:13
-
-
Save mx-moth/753922 to your computer and use it in GitHub Desktop.
This program will segfault when the second text box is focused.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
var fs, gtk; | |
gtk = require('node-gtk'); | |
fs = require('fs'); | |
process.nextTick(function() { | |
var crasher, good, event, hbox, submit, window, i, len; | |
gtk.init(); | |
console.log('Creating'); | |
crasher = new gtk.Entry; | |
events = ['changed', 'focus']; | |
for (i = 0, len = events.length; i < len; ++i) { | |
event = events[i]; | |
console.log('attaching', event); | |
crasher.on(event, function() { | |
console.log('fired:', event); | |
console.log(arguments.length); | |
return true; | |
}); | |
}; | |
good = new gtk.Entry; | |
hbox = new gtk.Hbox; | |
hbox.add(good); | |
hbox.add(crasher); | |
window = new gtk.Window; | |
window.add(hbox); | |
window.setTitle('Testing'); | |
window.setResizable(false); | |
window.setDefaultSize(400, 20); | |
console.log('Showing'); | |
return window.show(); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment