explicit casting of a parameter in pthread_start call

putting Xlib specific stuff (XInitThreads) in #ifdef
This commit is contained in:
Dmitrii V Pasechnik 2001-01-04 00:04:12 +00:00
parent 6f3579d41f
commit 04c6b10d93
2 changed files with 4 additions and 2 deletions

View File

@ -20,7 +20,7 @@
// (Mariette Yvinec <Mariette.Yvinec@sophia.inria.fr>)
//
// ============================================================================
#include <config.h> // fltk's config
// #include <config.h> // fltk's config
#include <FL/Fl.H> // order of includes is important on Windows.
#include <FL/gl.h>
#include <FL/Fl_Gl_Window.H>

View File

@ -1094,7 +1094,7 @@ pthread_t Viewer_3::get_window_thread()
void Viewer_3::init_window_thread()
{
pthread_create(&thr1, NULL, &mainloop, this);
pthread_create(&thr1, NULL, reinterpret_cast<void *(*)(void *)>(&mainloop), this);
}
#endif
@ -1107,7 +1107,9 @@ void Viewer_3::display()
void Viewer_3::init_window()
{
#ifdef USE_THREAD
#ifndef WIN32 // a temporary solution ?
XInitThreads();
#endif
#endif
form = new Fl_Window(size,size,"CGAL Viewer");