mirror of
https://github.com/Lekensteyn/ltunify.git
synced 2025-12-09 02:03:22 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b68dc9af6d |
@@ -1214,7 +1214,10 @@ int open_hidraw(void) {
|
||||
if (pid == PID_NANO_RECEIVER_2) {
|
||||
int iface = -1;
|
||||
if ((fp = fopen_format("/sys/class/hidraw/%s/device/../bInterfaceNumber", dev_name))) {
|
||||
fscanf(fp, "%02x", &iface);
|
||||
int m = fscanf(fp, "%02x", &iface);
|
||||
if (m != 1) {
|
||||
iface = -1;
|
||||
}
|
||||
fclose(fp);
|
||||
}
|
||||
if (iface == 0) {
|
||||
|
||||
Reference in New Issue
Block a user