--- mon/src/main.cpp 1999/10/04 21:16:02 1.2 +++ mon/src/main.cpp 2004/02/12 17:18:03 1.10 @@ -1,7 +1,7 @@ /* - * main.cpp - Wrapper program for standalone mon + * main.cpp - Wrapper program for standalone cxmon * - * mon (C) 1997-1999 Christian Bauer, Marc Hellwig + * cxmon (C) 1997-2004 Christian Bauer, Marc Hellwig * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -23,10 +23,11 @@ #include "mon.h" -#if __BEOS__ +#ifdef __BEOS__ #include #include #include +#include // Detect if program was launched from Shell or Tracker static bool launched_from_tracker(void) @@ -62,14 +63,14 @@ static bool open_stdio(const char *title strcat(term_path, "/Terminal"); // Load "Terminal" - char *t_argv[6]; + const char *t_argv[6]; t_argv[0] = term_path; t_argv[1] = "-t"; t_argv[2] = (char *)title; t_argv[3] = "/bin/debug_glue"; t_argv[4] = key_name; t_argv[5] = sem_id_str; - thread_id th = load_image(6, t_argv, environ); + thread_id th = load_image(6, t_argv, (const char **)environ); if (th < 0) { delete_sem(glue_sem); return false; @@ -101,7 +102,7 @@ static bool open_stdio(const char *title // Main program int main(int argc, char **argv) { -#if __BEOS__ +#ifdef __BEOS__ // Launched from Tracker? Then open terminal window if (launched_from_tracker()) { if (!open_stdio("mon"))