r3567 - trunk/src/target/gsm/src/libgsmd

tick at sita.openmoko.org tick at sita.openmoko.org
Wed Dec 5 04:10:43 CET 2007


Author: tick
Date: 2007-12-05 04:10:40 +0100 (Wed, 05 Dec 2007)
New Revision: 3567

Modified:
   trunk/src/target/gsm/src/libgsmd/libgsmd_passthrough.c
Log:
gsmd: decrease the rx_len for memcpy (Andrzej Zaborowski)


Modified: trunk/src/target/gsm/src/libgsmd/libgsmd_passthrough.c
===================================================================
--- trunk/src/target/gsm/src/libgsmd/libgsmd_passthrough.c	2007-12-05 01:54:47 UTC (rev 3566)
+++ trunk/src/target/gsm/src/libgsmd/libgsmd_passthrough.c	2007-12-05 03:10:40 UTC (rev 3567)
@@ -83,7 +83,7 @@
 	if (rc < sizeof(*rgmh) + rgmh->len)
 		return -EINVAL;
 
-	rx[(*rx_len)-1] = 0;
+	rx[--*rx_len] = 0;
 	if (rgmh->len < *rx_len)
 		*rx_len = rgmh->len;
 	memcpy(rx, rx_buf, *rx_len);





More information about the commitlog mailing list