CVS: rdesktop rdpsnd_dsp.c,1.26,1.27

Jay Sorg <[email protected]> Fri, 09 Feb 2007 23:12:38 -0800
Newsgroups gmane.network.rdesktop.cvs
Message-ID <[email protected]>
Update of /cvsroot/rdesktop/rdesktop
In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv27745

Modified Files:
	rdpsnd_dsp.c 
Log Message:
remove g++ errors and warnings

Index: rdpsnd_dsp.c
===================================================================
RCS file: /cvsroot/rdesktop/rdesktop/rdpsnd_dsp.c,v
retrieving revision 1.26
retrieving revision 1.27
diff -C2 -d -r1.26 -r1.27
*** rdpsnd_dsp.c	8 Jan 2007 04:47:06 -0000	1.26
--- rdpsnd_dsp.c	10 Feb 2007 07:12:36 -0000	1.27
***************
*** 120,124 ****
  		return;
  
! 	for (i = 0; i < size; i += 2)
  	{
  		swap = *(buffer + i);
--- 120,124 ----
  		return;
  
! 	for (i = 0; i < (int) size; i += 2)
  	{
  		swap = *(buffer + i);
***************
*** 202,206 ****
  	{
  		int newsize = (size / format->nChannels) * resample_to_channels;
! 		tmpdata = xmalloc(newsize);
  
  		for (i = 0; i < newsize / samplewidth; i++)
--- 202,206 ----
  	{
  		int newsize = (size / format->nChannels) * resample_to_channels;
! 		tmpdata = (unsigned char *) xmalloc(newsize);
  
  		for (i = 0; i < newsize / samplewidth; i++)
***************
*** 233,238 ****
  		{
  			tmp = tmpdata;
! 			tmpdata = xmalloc(size * 2);
! 			for (i = 0; i < size; i++)
  			{
  				tmpdata[i * 2] = in[i];
--- 233,238 ----
  		{
  			tmp = tmpdata;
! 			tmpdata = (unsigned char *) xmalloc(size * 2);
! 			for (i = 0; i < (int) size; i++)
  			{
  				tmpdata[i * 2] = in[i];
***************
*** 260,265 ****
  	outnum = ((float) innum * ((float) resample_to_srate / (float) format->nSamplesPerSec)) + 1;
  
! 	infloat = xmalloc(sizeof(float) * innum);
! 	outfloat = xmalloc(sizeof(float) * outnum);
  
  	src_short_to_float_array((short *) in, infloat, innum);
--- 260,265 ----
  	outnum = ((float) innum * ((float) resample_to_srate / (float) format->nSamplesPerSec)) + 1;
  
! 	infloat = (float *) xmalloc(sizeof(float) * innum);
! 	outfloat = (float *) xmalloc(sizeof(float) * outnum);
  
  	src_short_to_float_array((short *) in, infloat, innum);
***************
*** 279,283 ****
  
  	outsize = resample_data.output_frames_gen * resample_to_channels * samplewidth;
! 	*out = xmalloc(outsize);
  	src_float_to_short_array(outfloat, (short *) *out,
  				 resample_data.output_frames_gen * resample_to_channels);
--- 279,283 ----
  
  	outsize = resample_data.output_frames_gen * resample_to_channels * samplewidth;
! 	*out = (unsigned char *) xmalloc(outsize);
  	src_float_to_short_array(outfloat, (short *) *out,
  				 resample_data.output_frames_gen * resample_to_channels);
***************
*** 295,299 ****
  
  	outsize = outnum * samplewidth;
! 	*out = xmalloc(outsize);
  	bzero(*out, outsize);
  
--- 295,299 ----
  
  	outsize = outnum * samplewidth;
! 	*out = (unsigned char *) xmalloc(outsize);
  	bzero(*out, outsize);
  
***************
*** 306,310 ****
  		int j;
  
! 		if (source * resample_to_channels + samplewidth > size)
  			break;
  
--- 306,310 ----
  		int j;
  
! 		if (source * resample_to_channels + samplewidth > (int) size)
  			break;
  
***************
*** 411,415 ****
  	if (out.data == NULL)
  	{
! 		out.data = xmalloc(size);
  		memcpy(out.data, data, size);
  		out.size = size;
--- 411,415 ----
  	if (out.data == NULL)
  	{
! 		out.data = (unsigned char *) xmalloc(size);
  		memcpy(out.data, data, size);
  		out.size = size;


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642