(svn r1840) Repel str_buffr and use local buffers where possible

This commit is contained in:
tron
2005-02-07 12:32:35 +00:00
parent f8d97a5f61
commit b1baa4ed8b
7 changed files with 35 additions and 30 deletions

View File

@@ -505,6 +505,7 @@ static byte getNews(byte i)
// cut string after len pixels
static void GetNewsString(NewsItem *ni, char *buffer, uint max)
{
char buf[512];
StringID str;
const char *s;
char *d;
@@ -517,10 +518,9 @@ static void GetNewsString(NewsItem *ni, char *buffer, uint max)
str = ni->string_id;
}
GetString(str_buffr, str);
assert(strlen(str_buffr) < sizeof(str_buffr) - 1);
GetString(buf, str);
s = str_buffr;
s = buf;
d = buffer;
for (;; s++) {