diff options
Diffstat (limited to 'examples')
| -rw-r--r-- | examples/howto-add_fd-and-popen.cxx | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/examples/howto-add_fd-and-popen.cxx b/examples/howto-add_fd-and-popen.cxx index ef7e07bba..d649fd456 100644 --- a/examples/howto-add_fd-and-popen.cxx +++ b/examples/howto-add_fd-and-popen.cxx @@ -32,22 +32,22 @@ // http://www.fltk.org/str.php // #include <stdio.h> -#ifdef _WIN32 -#define PING_CMD "ping -n 10 localhost" // 'slow command' under windows -#ifdef _MSC_VER -#define popen _popen -#define pclose _pclose -#else /*_MSC_VER*/ -#include <unistd.h> // non-MS win32 compilers (untested) -#endif /*_MSC_VER*/ -#else -#include <unistd.h> -#define PING_CMD "ping -i 2 -c 10 localhost" // 'slow command' under unix -#endif #include <FL/Fl.H> #include <FL/Fl_Window.H> #include <FL/Fl_Multi_Browser.H> +#ifdef _WIN32 +# define PING_CMD "ping -n 10 localhost" // 'slow command' under windows +# ifdef _MSC_VER +# define popen _popen +# define pclose _pclose +# else /*_MSC_VER*/ +# include <unistd.h> // non-MS win32 compilers (untested) +# endif /*_MSC_VER*/ +#else +# include <unistd.h> +# define PING_CMD "ping -i 2 -c 10 localhost" // 'slow command' under unix +#endif // GLOBALS FILE *G_fp = NULL; |
