summaryrefslogtreecommitdiff
path: root/libs
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2016-02-19 23:16:38 +0100
committerRobin Gareus <robin@gareus.org>2016-02-19 23:16:38 +0100
commit9633ea3b01286946a0ce6a90c9c7835aad793e74 (patch)
tree7a9072e7841faa78da442b8088dc2cb79638991b /libs
parentb0518fa2be9bd078647ac3af6822b89f8897c899 (diff)
fix Windows OSC support
Diffstat (limited to 'libs')
-rw-r--r--libs/surfaces/osc/osc.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/libs/surfaces/osc/osc.cc b/libs/surfaces/osc/osc.cc
index f51da269ab..f83e119d75 100644
--- a/libs/surfaces/osc/osc.cc
+++ b/libs/surfaces/osc/osc.cc
@@ -251,7 +251,12 @@ OSC::thread_init ()
}
if (_osc_server) {
+#ifdef PLATFORM_WINDOWS
+ lib::RefPtr<IOChannel> iochan = Glib::IOChannel::create_from_win32_socket (lo_server_get_socket_fd (_osc_server));
+ Glib::RefPtr<IOSource> src = IOSource::create (chan, IO_IN|IO_HUP|IO_ERR);
+#else
Glib::RefPtr<IOSource> src = IOSource::create (lo_server_get_socket_fd (_osc_server), IO_IN|IO_HUP|IO_ERR);
+#endif
src->connect (sigc::bind (sigc::mem_fun (*this, &OSC::osc_input_handler), _osc_server));
src->attach (_main_loop->get_context());
remote_server = src->gobj();