cl_main.c: More VID_SetCaption status messages.

vid_*: Make it so that VID_SetCaption can be safely called with the output
from va()
This commit is contained in:
Jeff Teunissen 2000-10-14 07:10:56 +00:00
parent 5e8b620b9d
commit e0a53aa9a2
6 changed files with 37 additions and 21 deletions

View file

@ -519,18 +519,19 @@ IN_Move (usercmd_t *cmd)
}
void VID_InitCvars ()
void
VID_InitCvars (void)
{
// It may not look like it, but this is important
}
void
VID_LockBuffer ( void )
VID_LockBuffer (void)
{
}
void
VID_UnlockBuffer ( void )
VID_UnlockBuffer (void)
{
}
@ -538,9 +539,11 @@ void
VID_SetCaption (char *text)
{
if (text && *text) {
SDL_WM_SetCaption(va ("%s %s: %s", PROGRAM, VERSION, text), NULL);
char *temp = strdup (text);
SDL_WM_SetCaption (va ("%s %s: %s", PROGRAM, VERSION, temp), NULL);
free (temp);
} else {
SDL_WM_SetCaption(va ("%s %s", PROGRAM, VERSION), NULL);
SDL_WM_SetCaption (va ("%s %s", PROGRAM, VERSION), NULL);
}
}