r679 - trunk

lordhavoc at icculus.org lordhavoc at icculus.org
Mon Mar 27 04:07:19 EST 2006


Author: lordhavoc
Date: 2006-03-27 04:07:18 -0500 (Mon, 27 Mar 2006)
New Revision: 679

Modified:
   trunk/lhsound.c
   trunk/sound.c
Log:
fix a couple warnings


Modified: trunk/lhsound.c
===================================================================
--- trunk/lhsound.c	2006-03-26 08:40:05 UTC (rev 678)
+++ trunk/lhsound.c	2006-03-27 09:07:18 UTC (rev 679)
@@ -462,7 +462,7 @@
 
 	while (lhsound_state.numsamples > 0)
 	{
-		int number = --lhsound_state.numsamples;
+		unsigned int number = --lhsound_state.numsamples;
 		lhsoundDeleteSamples(1, &number);
 	}
 	lhsoundClearMemory(&lhsound_state, 0, sizeof(lhsound_state));
@@ -510,7 +510,7 @@
 	LHSOUNDASSERT(bufferlength == lhsound_state.mixbufferlength, LHSOUND_ERROR_INVALID_VALUE);
 	LHSOUNDASSERT(stride != 0, LHSOUND_ERROR_INVALID_VALUE);
 	lhsound_state.mixbeginstate = LHSOUND_FALSE;
-	
+
 	swaptest.s = 1;
 	switch (format)
 	{
@@ -635,6 +635,6 @@
 		default:
 			break;
 		}
-	}	
+	}
 }
 

Modified: trunk/sound.c
===================================================================
--- trunk/sound.c	2006-03-26 08:40:05 UTC (rev 678)
+++ trunk/sound.c	2006-03-27 09:07:18 UTC (rev 679)
@@ -199,8 +199,8 @@
 	SoundInfo info;
 	int channelcount;
 	int channel;
-	int samplenumber[SOUND_MAX_CHANNEL_COUNT];
-	
+	unsigned int samplenumber[SOUND_MAX_CHANNEL_COUNT];
+
 	if (!Sound_LoadWaveFile(r->name, &info, r->memzone))
 	{
 		Console_Printf("Sound_Load: failed to load \"%s\" - error: %s\n", r->name, info.errormessage);
@@ -212,7 +212,7 @@
 	// bind the sounds and load them
 	for( channel = 0 ; channel < channelcount ; channel++ )
 	{
-		void *channelStart = (NUint8*) info.data + channel * info.bytespersample; 
+		void *channelStart = (NUint8*) info.data + channel * info.bytespersample;
 
 		lhsoundBindSample(samplenumber[channel]);
 		lhsoundSample(info.length, info.lhsoundformat, info.channels, channelStart);




More information about the neither-commits mailing list