From: Rudolf Polzer Date: Wed, 20 Apr 2011 15:50:29 +0000 (+0200) Subject: fix two more bugs X-Git-Tag: xonotic-v0.5.0~34 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=d4500cb5d9f8760e3decea477d1bb64e2bc2d73a;p=xonotic%2Fnetradiant.git fix two more bugs --- diff --git a/tools/quake3/q3map2/path_init.c b/tools/quake3/q3map2/path_init.c index 5369c312..501317f6 100644 --- a/tools/quake3/q3map2/path_init.c +++ b/tools/quake3/q3map2/path_init.c @@ -75,7 +75,7 @@ char *LokiGetHomeDir( void ) TCHAR mydocsdir[MAX_PATH + 1]; if(SHGetFolderPath(NULL, CSIDL_PERSONAL, NULL, 0, mydocsdir)) { - snprintf(buf, "%s/My Games", mydocsdir); + snprintf(buf, sizeof(buf), "%s/My Games", mydocsdir); return buf; } return NULL; @@ -119,6 +119,8 @@ initializes some paths on linux/os x void LokiInitPaths( char *argv0 ) { #ifndef Q_UNIX + char *home; + /* this is kinda crap, but hey */ strcpy( installPath, "../" );