diff --git a/src/dedicated/i_system.c b/src/dedicated/i_system.c index 413b366b8..82dd51be0 100644 --- a/src/dedicated/i_system.c +++ b/src/dedicated/i_system.c @@ -1433,9 +1433,15 @@ static const char *locateWad(void) #ifndef NOHOME // find in $HOME - I_OutputMsg(",HOME"); + I_OutputMsg(",HOME/" DEFAULTDIR); if ((envstr = I_GetEnv("HOME")) != NULL) + { + char *tmp = malloc(strlen(envstr) + sizeof(DEFAULTDIR)); + strcpy(tmp, envstr); + strcat(tmp, DEFAULTDIR); SEARCHWAD(envstr); + free(tmp); + } #endif // search paths diff --git a/src/sdl/i_system.c b/src/sdl/i_system.c index b7b995c6f..e28fbd34a 100644 --- a/src/sdl/i_system.c +++ b/src/sdl/i_system.c @@ -3050,9 +3050,15 @@ static const char *locateWad(void) #ifndef NOHOME // find in $HOME - I_OutputMsg(",HOME"); + I_OutputMsg(",HOME/" DEFAULTDIR); if ((envstr = I_GetEnv("HOME")) != NULL) + { + char *tmp = malloc(strlen(envstr) + sizeof(DEFAULTDIR)); + strcpy(tmp, envstr); + strcat(tmp, DEFAULTDIR); SEARCHWAD(envstr); + free(tmp); + } #endif // search paths