diff --git a/sc2/src/sc2code/commglue.c b/sc2/src/sc2code/commglue.c index d90890efa..9b7d9a838 100644 --- a/sc2/src/sc2code/commglue.c +++ b/sc2/src/sc2code/commglue.c @@ -21,6 +21,8 @@ #include "races.h" #include +#include +#include #include int NPCNumberPhrase (int number, UNICODE **ptrack); @@ -281,7 +283,7 @@ construct_response (UNICODE *buf, int R /* promoted from RESPONSE_REF */, ...) // XXX: this should someday be changed so that the function takes // the buffer size as an argument if ((buf_start == shared_phrase_buf) && - (buf - shared_phrase_buf > sizeof (shared_phrase_buf))) + (buf - shared_phrase_buf > (ptrdiff_t) sizeof (shared_phrase_buf))) { fprintf (stderr, "Error: shared_phrase_buf size exceeded," " please increase!\n"); diff --git a/sc2/src/sc2code/libs/strings/unicode.c b/sc2/src/sc2code/libs/strings/unicode.c index 1f41bd6ff..fbbe49d7b 100644 --- a/sc2/src/sc2code/libs/strings/unicode.c +++ b/sc2/src/sc2code/libs/strings/unicode.c @@ -16,6 +16,7 @@ #include "port.h" +#include #include #include #include