? server2 ? tmp ? edit ? tmp2 ? client/civgame.log ? data/engels Index: client/citydlg.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/citydlg.c,v retrieving revision 1.26 diff -u -r1.26 citydlg.c --- citydlg.c 1999/01/12 11:21:56 1.26 +++ citydlg.c 1999/01/28 14:46:05 @@ -46,6 +46,7 @@ #include #include #include +#include extern Display *display; extern Widget toplevel, main_form, map_canvas; Index: client/civclient.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/civclient.c,v retrieving revision 1.21 diff -u -r1.21 civclient.c --- civclient.c 1999/01/24 03:53:13 1.21 +++ civclient.c 1999/01/28 14:46:05 @@ -43,7 +43,6 @@ char server_host[512]; char name[512]; int server_port; -int is_server = 0; enum client_states client_state=CLIENT_BOOT_STATE; int use_solid_color_behind_units; @@ -104,6 +103,8 @@ fprintf(stderr, "%s\n", FREECIV_NAME_VERSION); exit(0); } + + is_server = 0; /* audio_init(); */ init_messages_where(); Index: client/climisc.h =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/climisc.h,v retrieving revision 1.6 diff -u -r1.6 climisc.h --- climisc.h 1999/01/28 11:05:57 1.6 +++ climisc.h 1999/01/28 14:46:05 @@ -7,6 +7,7 @@ char *tilefilename(char *name); void climap_init_continents(void); void climap_update_continents(int x, int y); +struct city *find_city_by_id(int id); #endif Index: client/dialogs.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/dialogs.c,v retrieving revision 1.19 diff -u -r1.19 dialogs.c --- dialogs.c 1998/10/20 12:32:39 1.19 +++ dialogs.c 1999/01/28 14:46:05 @@ -37,6 +37,7 @@ #include #include #include +#include extern Widget toplevel, main_form, map_canvas; Index: client/diplodlg.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/diplodlg.c,v retrieving revision 1.2 diff -u -r1.2 diplodlg.c --- diplodlg.c 1999/01/17 09:44:27 1.2 +++ diplodlg.c 1999/01/28 14:46:06 @@ -35,6 +35,7 @@ #include #include #include +#include #include #include #include Index: client/mapctrl.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/mapctrl.c,v retrieving revision 1.26 diff -u -r1.26 mapctrl.c --- mapctrl.c 1999/01/12 10:55:44 1.26 +++ mapctrl.c 1999/01/28 14:46:06 @@ -38,6 +38,7 @@ #include #include #include +#include #include #include #include Index: client/repodlgs.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/repodlgs.c,v retrieving revision 1.37 diff -u -r1.37 repodlgs.c --- repodlgs.c 1999/01/23 05:07:37 1.37 +++ repodlgs.c 1999/01/28 14:46:06 @@ -48,6 +48,7 @@ #include #include #include +#include extern Widget toplevel, main_form, map_canvas; Index: client/xmain.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/client/xmain.c,v retrieving revision 1.29 diff -u -r1.29 xmain.c --- xmain.c 1999/01/24 02:33:54 1.29 +++ xmain.c 1999/01/28 14:46:07 @@ -261,7 +261,11 @@ /* include later - pain to see the warning at every run */ /* XtSetLanguageProc(NULL, (XtLanguageProc)NULL, NULL); */ - toplevel = XtVaAppInitialize( + Display *d; + if ((d = XOpenDisplay(getenv("DISPLAY"))) == NULL) { + fprintf(stderr, "Can't open X-Windows display.\n"); + exit(1); + } else toplevel = XtVaAppInitialize( &app_context, /* Application context */ "Freeciv", /* application class name */ options, XtNumber(options), /* command line option list */ Index: common/city.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/city.c,v retrieving revision 1.30 diff -u -r1.30 city.c --- city.c 1999/01/28 11:14:28 1.30 +++ city.c 1999/01/28 14:46:07 @@ -1257,7 +1257,7 @@ * (Note player_find_city_by_id() may be faster, in the client) */ if (id==B_MANHATTEN) - return (find_city_by_id(game.global_wonders[id]) != 0); + return (game_find_city_by_id(game.global_wonders[id]) != 0); tmp = player_find_city_by_id(get_player(pcity->owner), game.global_wonders[id]); Index: common/city.h =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/city.h,v retrieving revision 1.25 diff -u -r1.25 city.h --- city.h 1999/01/28 11:14:29 1.25 +++ city.h 1999/01/28 14:46:07 @@ -219,7 +219,6 @@ int city_num_trade_routes(struct city *pcity); /* list functions */ -struct city *find_city_by_id(int id); /* this funct is no longer in this module, but leaving it proto'd here saves more headaches than you can imagine -- Syela */ void city_list_init(struct city_list *This); Index: common/game.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/game.c,v retrieving revision 1.29 diff -u -r1.29 game.c --- game.c 1999/01/28 11:51:47 1.29 +++ game.c 1999/01/28 14:46:07 @@ -26,7 +26,6 @@ #endif void dealloc_id(int id); -extern int is_server; struct civ_game game; /* Index: common/player.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/player.c,v retrieving revision 1.15 diff -u -r1.15 player.c --- player.c 1999/01/28 11:14:30 1.15 +++ player.c 1999/01/28 14:46:07 @@ -21,8 +21,6 @@ #include #include -extern int is_server; - struct player_race races[]= { /* additional goals added by Syela */ {"Roman", "Romans", 1, 2, 2, {100,100,100,100,100,100,100}, @@ -342,7 +340,7 @@ struct city *pcity; if(is_server) { - pcity = find_city_by_id(city_id); + pcity = game_find_city_by_id(city_id); if(pcity && (pcity->owner==pplayer->player_no)) { return pcity; } else { Index: common/shared.h =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/shared.h,v retrieving revision 1.30 diff -u -r1.30 shared.h --- shared.h 1999/01/20 10:31:07 1.30 +++ shared.h 1999/01/28 14:46:07 @@ -108,5 +108,6 @@ void save_restore_random(void); char *datafilename(char *filename); /* used to be in client/climisc */ +int is_server; #endif Index: server/cityhand.h =================================================================== RCS file: /home/freeciv/CVS/freeciv/server/cityhand.h,v retrieving revision 1.8 diff -u -r1.8 cityhand.h --- cityhand.h 1998/07/20 14:34:11 1.8 +++ cityhand.h 1999/01/28 14:46:07 @@ -17,6 +17,8 @@ #include "city.h" /* citycache */ +struct city *find_city_by_id(int id); + void initialize_city_cache(void); void add_city_to_cache(struct city *pcity); void remove_city_from_cache(int id); Index: server/civserver.c =================================================================== RCS file: /home/freeciv/CVS/freeciv/server/civserver.c,v retrieving revision 1.59 diff -u -r1.59 civserver.c --- civserver.c 1999/01/17 11:29:13 1.59 +++ civserver.c 1999/01/28 14:46:07 @@ -93,7 +93,6 @@ /* use get_next_id_number() */ unsigned short global_id_counter=100; unsigned char used_ids[8192]={0}; -int is_server = 1; int is_new_game=1; @@ -126,6 +125,8 @@ int log_level=LOG_NORMAL; strcpy(metaserver_info_line, DEFAULT_META_SERVER_INFO_STRING); + + is_server = 1; /* no we don't use GNU's getopt or even the "standard" getopt */ /* yes we do have reasons ;) */