Always use COM_CreatPath instead of Sys_mkdir

This commit is contained in:
Bill Currie 2000-11-08 06:07:03 +00:00
parent 631d5f470c
commit d31a9f73de
3 changed files with 3 additions and 16 deletions

View file

@ -1111,8 +1111,6 @@ CL_Download_f
*/
void CL_Download_f (void)
{
char *p, *q;
if (cls.state == ca_disconnected)
{
Con_Printf ("Must be connected.\n");
@ -1127,16 +1125,7 @@ void CL_Download_f (void)
snprintf (cls.downloadname, sizeof(cls.downloadname), "%s/%s", com_gamedir, Cmd_Argv(1));
p = cls.downloadname;
for (;;) {
if ((q = strchr(p, '/')) != NULL) {
*q = 0;
Sys_mkdir(cls.downloadname);
*q = '/';
p = q + 1;
} else
break;
}
COM_CreatePath (cls.downloadname);
strncpy (cls.downloadtempname, cls.downloadname, sizeof(cls.downloadtempname));
cls.download = Qopen (cls.downloadname, "wb");

View file

@ -777,8 +777,7 @@ void SV_Snap (int uid)
sprintf(pcxname, "%d-00.pcx", uid);
snprintf (checkname, sizeof(checkname), "%s/snap", com_gamedir);
Sys_mkdir(com_gamedir);
Sys_mkdir(checkname);
COM_CreatePath (va ("%s/dummy", checkname));
for (i=0 ; i<=99 ; i++)
{

View file

@ -767,9 +767,8 @@ VID_SetPalette (unsigned char *palette)
}
d_15to8table[i]=k;
}
snprintf(s, sizeof(s), "%s/glquake", com_gamedir);
Sys_mkdir (s);
snprintf(s, sizeof(s), "%s/glquake/15to8.pal", com_gamedir);
COM_CreatePath (s);
if ((f = Qopen(s, "wb")) != NULL) {
Qwrite(f, d_15to8table, 1<<15);
Qclose(f);