Probleme in stdbool.h führen zu nichtauswertung. unter GNUC wird für

'boolean' jetzt auch ein int verwendet, besser das.
This commit is contained in:
Enno Rehling 2003-12-17 10:28:23 +00:00
parent 905f5d6a0d
commit a56dc25068
4 changed files with 8 additions and 6 deletions

View File

@ -846,7 +846,7 @@ read_alliances(FILE * F)
#endif #endif
int int
readgame(const char * filename, boolean backup) readgame(const char * filename, int backup)
{ {
int i, n, p; int i, n, p;
faction *f, **fp; faction *f, **fp;

View File

@ -36,7 +36,7 @@ double version(void);
FILE * cfopen(const char *filename, const char *mode); FILE * cfopen(const char *filename, const char *mode);
int readorders(const char *); int readorders(const char *);
int creategame(void); int creategame(void);
extern int readgame(const char * filename, boolean backup); extern int readgame(const char * filename, int backup);
void writegame(const char *filename, char quiet); void writegame(const char *filename, char quiet);
extern void rsf(FILE * F, char *s, size_t len); extern void rsf(FILE * F, char *s, size_t len);

View File

@ -48,7 +48,8 @@
#if defined(__GNUC__) #if defined(__GNUC__)
# include <stdbool.h> # include <stdbool.h>
# define HAS_BOOLEAN # define HAS_BOOLEAN
# define boolean bool typedef int boolean;
/* # define boolean bool */
#endif #endif
#if defined(_DEBUG) && defined(_MSC_VER) #if defined(_DEBUG) && defined(_MSC_VER)

View File

@ -25,7 +25,7 @@
#endif #endif
#include <config.h> #include <config.h>
#include <eressea.h> #include "eressea.h"
#include "korrektur.h" #include "korrektur.h"
@ -706,8 +706,9 @@ main(int argc, char *argv[])
return 0; return 0;
#endif #endif
sprintf(buf, "%d", turn); sprintf(zText, "%d", turn);
if ((i=readgame(buf, false))!=0) return i; i=readgame(zText, false);
if (i!=0) return i;
#ifdef NEW_STARTEQUIPMENT #ifdef NEW_STARTEQUIPMENT
add_equipment(it_find("conquesttoken"), 1); add_equipment(it_find("conquesttoken"), 1);