From: molivier Date: Mon, 5 Jul 2004 13:28:58 +0000 (+0000) Subject: Fixed a crash when using "-nosound" X-Git-Tag: xonotic-v0.1.0preview~5801 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=053629ead3d4541a06d7bf88e38df1ba0e5464ba;p=xonotic%2Fdarkplaces.git Fixed a crash when using "-nosound" git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4261 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/snd_dma.c b/snd_dma.c index 01e48254..9dc66365 100644 --- a/snd_dma.c +++ b/snd_dma.c @@ -305,6 +305,9 @@ sfx_t *S_FindName (const char *name, qboolean stdpath) { sfx_t *sfx; + if (!snd_initialized.integer) + return NULL; + sfx = S_GetCached (name, stdpath); // If we haven't allocated a sfx_t struct for it yet