[asterisk-addons-commits] mnicholson: branch mnicholson/chan-mobile-refactor r740 - /team/mnicholson/ch...

SVN commits to the Asterisk addons project asterisk-addons-commits at lists.digium.com
Mon Jan 26 11:14:38 CST 2009


Author: mnicholson
Date: Mon Jan 26 11:14:37 2009
New Revision: 740

URL: http://svn.digium.com/svn-view/asterisk-addons?view=rev&rev=740
Log:
Fixed some errors in rfcomm_read

Modified:
    team/mnicholson/chan-mobile-refactor/channels/chan_mobile.c

Modified: team/mnicholson/chan-mobile-refactor/channels/chan_mobile.c
URL: http://svn.digium.com/svn-view/asterisk-addons/team/mnicholson/chan-mobile-refactor/channels/chan_mobile.c?view=diff&rev=740&r1=739&r2=740
==============================================================================
--- team/mnicholson/chan-mobile-refactor/channels/chan_mobile.c (original)
+++ team/mnicholson/chan-mobile-refactor/channels/chan_mobile.c Mon Jan 26 11:14:37 2009
@@ -1054,7 +1054,7 @@
  * the given buffer is not large enough to hold the response, what does not fit
  * in the buffer will be dropped.
  */
-static ssize_t rfcomm_read(int rsock, char *buf, int count)
+static ssize_t rfcomm_read(int rsock, char *buf, size_t count)
 {
 
 	ssize_t res;
@@ -1069,7 +1069,7 @@
 			break;
 		
 		/* check for '\r\n' */
-		if (got_cr && c = '\n') {
+		if (got_cr && c == '\n') {
 			got_cr = 0;
 			if (have_msg)
 				break;
@@ -1084,7 +1084,7 @@
 				in_count++;
 				*buf++ = '\r';
 			}
-		} else if (c = '\r') {
+		} else if (c == '\r') {
 			got_cr = 1;
 			continue;
 		}




More information about the asterisk-addons-commits mailing list