From: Tormod Volden <debian.tor...@gmail.com> --- src/dfu.h | 1 + src/main.c | 5 +++++ 2 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/src/dfu.h b/src/dfu.h index 6d2347a..9e6fda7 100644 --- a/src/dfu.h +++ b/src/dfu.h @@ -96,6 +96,7 @@ struct dfu_if { u_int8_t configuration; u_int8_t interface; u_int8_t altsetting; + unsigned char *alt_name; int bus; u_int8_t devnum; const char *path; diff --git a/src/main.c b/src/main.c index 9146920..0b1cd36 100644 --- a/src/main.c +++ b/src/main.c @@ -513,6 +513,7 @@ int main(int argc, char **argv) libusb_context *ctx; struct dfu_file file; char *alt_name = NULL; /* query alt name if non-NULL */ + unsigned char active_alt_name[MAX_STR_LEN+1]; char *end; int final_reset = 0; int ret; @@ -809,6 +810,10 @@ dfustate: exit(1); } print_dfu_if(dif, NULL); + if (get_alt_name(dif, active_alt_name) > 0) + dif->alt_name = active_alt_name; + else + dif->alt_name = NULL; #if 0 printf("Setting Configuration %u...\n", dif->configuration); -- 1.7.5.4 _______________________________________________ devel mailing list devel@lists.openmoko.org https://lists.openmoko.org/mailman/listinfo/devel