1
0
forked from 0ad/0ad

fix stupid sizeof bug reported by philip

This was SVN commit r1981.
This commit is contained in:
janwas 2005-03-10 00:47:23 +00:00
parent cdecd9b242
commit 2e13ec5ff1

View File

@ -215,7 +215,7 @@ static int get_ogl_drv_name(char* ogl_drv_name, const size_t max_name_len)
// add .dll to filename, if not already there // add .dll to filename, if not already there
char* ext = strrchr(ogl_drv_name, '.'); char* ext = strrchr(ogl_drv_name, '.');
if(!ext || stricmp(ext, ".dll") != 0) if(!ext || stricmp(ext, ".dll") != 0)
strcat_s(ogl_drv_name, sizeof(ogl_drv_name), ".dll"); strcat_s(ogl_drv_name, max_name_len, ".dll");
ret = 0; // success ret = 0; // success
} }