1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-08-31 02:19:09 +00:00

(svn r1616) Introduce ttd_strlcat() and use it to de-uglify some piece of code in misc_cmd.

While here rename the len parameter of ttd_strlcpy() to size, because it is a buffer size and not a string length.
Also add -Wwrite-strings to the Makefile, because the above mentioned piece of code was the only part which triggered this warning.
This commit is contained in:
tron
2005-01-23 15:16:47 +00:00
parent 9a96f5b64e
commit 53d1c3f117
4 changed files with 18 additions and 10 deletions

View File

@@ -271,7 +271,8 @@ enum {
};
void ShowSaveLoadDialog(int mode);
void ttd_strlcpy(char *dst, const char *src, size_t len);
void ttd_strlcpy(char *dst, const char *src, size_t size);
void ttd_strlcat(char *dst, const char *src, size_t size);
// callback from drivers that is called if the game size changes dynamically
void GameSizeChanged(void);