mirror of
https://github.com/ioquake/ioq3.git
synced 2024-11-10 07:11:46 +00:00
Fill in filename in Com_WriteConfig_f() before checking extension.
Thanks BartoCH for pointing out.
This commit is contained in:
parent
25cc2edc69
commit
de3339ebcd
1 changed files with 2 additions and 2 deletions
|
@ -2975,6 +2975,8 @@ void Com_WriteConfig_f( void ) {
|
|||
return;
|
||||
}
|
||||
|
||||
Q_strncpyz( filename, Cmd_Argv(1), sizeof( filename ) );
|
||||
COM_DefaultExtension( filename, sizeof( filename ), ".cfg" );
|
||||
|
||||
if (!COM_CompareExtension(filename, ".cfg"))
|
||||
{
|
||||
|
@ -2982,8 +2984,6 @@ void Com_WriteConfig_f( void ) {
|
|||
return;
|
||||
}
|
||||
|
||||
Q_strncpyz( filename, Cmd_Argv(1), sizeof( filename ) );
|
||||
COM_DefaultExtension( filename, sizeof( filename ), ".cfg" );
|
||||
Com_Printf( "Writing %s.\n", filename );
|
||||
Com_WriteConfigToFile( filename );
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue