s/ThrowFatal/Throw/

This commit is contained in:
Glenn Maynard
2002-12-21 18:32:06 +00:00
parent e7c32293da
commit 783a9de6b0
3 changed files with 7 additions and 8 deletions
+1 -1
View File
@@ -32,7 +32,7 @@ const char* RageException::what() const throw ()
return m_sError; return m_sError;
} }
RageException::ThrowFatal(const char *fmt, ...) RageException::Throw(const char *fmt, ...)
{ {
va_list va; va_list va;
va_start(va, fmt); va_start(va, fmt);
+4 -5
View File
@@ -23,11 +23,10 @@ public:
virtual const char *what() const throw(); virtual const char *what() const throw();
virtual ~RageException() throw() { } virtual ~RageException() throw() { }
/* The only difference between these is that ThrowFatal triggers debug /* The only difference between these is that Throw triggers debug behavior
* behavior, and Nonfatal doesn't. Nonfatal is used when the exception * and Nonfatal doesn't. Nonfatal is used when the exception happens
* happens normally and will be caught, such as when a driver fails to * normally and will be caught, such as when a driver fails to initialize. */
* initialize. */ static Throw(const char *fmt, ...);
static ThrowFatal(const char *fmt, ...);
static ThrowNonfatal(const char *fmt, ...); static ThrowNonfatal(const char *fmt, ...);
protected: protected:
@@ -106,7 +106,7 @@ bool RageSound_WaveOut::GetPCM()
MMRESULT ret = waveOutWrite(wo, &buffers[b], sizeof(buffers[b])); MMRESULT ret = waveOutWrite(wo, &buffers[b], sizeof(buffers[b]));
if(ret != MMSYSERR_NOERROR) if(ret != MMSYSERR_NOERROR)
RageException::ThrowFatal(wo_ssprintf(ret, "waveOutWrite failed")); RageException::Throw(wo_ssprintf(ret, "waveOutWrite failed"));
/* Increment last_cursor_pos. */ /* Increment last_cursor_pos. */
last_cursor_pos += chunksize_frames; last_cursor_pos += chunksize_frames;
@@ -167,7 +167,7 @@ int RageSound_WaveOut::GetPosition(const RageSound *snd) const
tm.wType = TIME_SAMPLES; tm.wType = TIME_SAMPLES;
MMRESULT ret = waveOutGetPosition(wo, &tm, sizeof(tm)); MMRESULT ret = waveOutGetPosition(wo, &tm, sizeof(tm));
if(ret != MMSYSERR_NOERROR) if(ret != MMSYSERR_NOERROR)
RageException::ThrowFatal(wo_ssprintf(ret, "waveOutGetPosition failed")); RageException::Throw(wo_ssprintf(ret, "waveOutGetPosition failed"));
return tm.u.sample; return tm.u.sample;
} }