mirror of
https://github.com/nzp-team/fteqw.git
synced 2024-11-12 23:44:39 +00:00
Fix servers trying to redirect players to downloading directory-packages as a single file (which will always fail).
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5434 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
b04b7b2b0a
commit
dc999091aa
1 changed files with 7 additions and 4 deletions
|
@ -1405,7 +1405,7 @@ char *FS_GetPackageDownloadFilename(flocation_t *loc)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sp && strchr(sp->purepath, '/')) //never allow any packages that are directly sitting in the basedir.
|
if (sp && strchr(sp->purepath, '/') && sp->handle->GeneratePureCRC) //never allow any packages that are directly sitting in the basedir.
|
||||||
return sp->purepath;
|
return sp->purepath;
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
@ -5817,12 +5817,15 @@ void FS_CreateBasedir(const char *path)
|
||||||
{
|
{
|
||||||
vfsfile_t *f;
|
vfsfile_t *f;
|
||||||
com_installer = false;
|
com_installer = false;
|
||||||
|
if (path)
|
||||||
|
{
|
||||||
Q_strncpyz (com_gamepath, path, sizeof(com_gamepath));
|
Q_strncpyz (com_gamepath, path, sizeof(com_gamepath));
|
||||||
COM_CreatePath(com_gamepath);
|
COM_CreatePath(com_gamepath);
|
||||||
|
}
|
||||||
fs_manifest->security = MANIFEST_SECURITY_INSTALLER;
|
fs_manifest->security = MANIFEST_SECURITY_INSTALLER;
|
||||||
FS_ChangeGame(fs_manifest, true, false);
|
FS_ChangeGame(fs_manifest, true, false);
|
||||||
|
|
||||||
if (host_parms.manifest)
|
if (path && host_parms.manifest)
|
||||||
{
|
{
|
||||||
f = FS_OpenVFS("default.fmf", "wb", FS_ROOT);
|
f = FS_OpenVFS("default.fmf", "wb", FS_ROOT);
|
||||||
if (f)
|
if (f)
|
||||||
|
|
Loading…
Reference in a new issue