git://developer.intra2net.com
/
libftdi
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
ca50957
)
cpp-wrapper: when using get-string-and-reopen method without having set up the usb...
author
Peter Schneider
<pitpompej@arcor.de>
Tue, 10 Jan 2012 10:09:11 +0000 (11:09 +0100)
committer
Thomas Jarosch
<thomas.jarosch@intra2net.com>
Mon, 16 Jan 2012 14:39:42 +0000 (15:39 +0100)
ftdipp/ftdi.cpp
patch
|
blob
|
blame
|
history
diff --git
a/ftdipp/ftdi.cpp
b/ftdipp/ftdi.cpp
index
5e45dce
..
f1c1cef
100644
(file)
--- a/
ftdipp/ftdi.cpp
+++ b/
ftdipp/ftdi.cpp
@@
-316,6
+316,11
@@
int Context::get_strings()
int Context::get_strings_and_reopen()
{
+ if ( d->dev == 0 )
+ {
+ d->dev = libusb_get_device(d->ftdi->usb_dev);
+ }
+
// Get device strings (closes device)
int ret=get_strings();
if (ret < 0)