fix threads problem in OpenBSD. Fixes #7154

This commit is contained in:
Denis Fomin 2012-05-09 12:16:48 +04:00
parent 4f7cdd557b
commit fbaf3becdb
1 changed files with 3 additions and 0 deletions

View File

@ -454,6 +454,9 @@ if __name__ == '__main__':
# This makes Gajim unusable under windows, and threads are used only
# for GPG, so not under windows
gtk.gdk.threads_init()
gtk.gdk.threads_enter()
gtk.main()
if os.name != 'nt':
gtk.gdk.threads_leave()
except KeyboardInterrupt:
print >> sys.stderr, 'KeyboardInterrupt'