r5916 - trunk/src/host/dfu-util/src

stefan at docs.openmoko.org stefan at docs.openmoko.org
Sun Apr 18 21:06:34 CEST 2010


Author: stefan
Date: 2010-04-18 21:06:33 +0200 (Sun, 18 Apr 2010)
New Revision: 5916

Modified:
   trunk/src/host/dfu-util/src/main.c
Log:
src/main.c: Fix last commit for good.

Thanks to Werner Almesberger for spotting this. Long standing problem. Due to
the bitwise AND instead of an logical AND check we always skipped this check and
dropped back to 0 which is loading into RAM on OM devices.

Modified: trunk/src/host/dfu-util/src/main.c
===================================================================
--- trunk/src/host/dfu-util/src/main.c	2010-04-18 16:43:41 UTC (rev 5915)
+++ trunk/src/host/dfu-util/src/main.c	2010-04-18 19:06:33 UTC (rev 5916)
@@ -707,7 +707,7 @@
 				"DFU IF\n");
 			exit(1);
 		}
-	} else if (num_ifs > 1 && (!dif->flags) & (DFU_IFF_IFACE|DFU_IFF_ALT)) {
+	} else if (num_ifs > 1 && !dif->flags && (DFU_IFF_IFACE|DFU_IFF_ALT)) {
 		fprintf(stderr, "We have %u DFU Interfaces/Altsettings, "
 			"you have to specify one via --intf / --alt options\n",
 			num_ifs);




More information about the commitlog mailing list