kopia lustrzana https://github.com/Hamlib/Hamlib
[simulators] Fix compiler warning
Adds the same code used in other simulators. Fixes: simft897.c:26:9: warning: variable ‘n’ set but not used [-Wunused-but-set-variable]pull/1860/head
rodzic
1aafbb3f24
commit
8f0c94dc77
|
@ -40,6 +40,7 @@ int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
printf("Not 5 bytes? bytes=%d\n", bytes);
|
printf("Not 5 bytes? bytes=%d\n", bytes);
|
||||||
}
|
}
|
||||||
|
n = 0;
|
||||||
|
|
||||||
switch (buf[4])
|
switch (buf[4])
|
||||||
{
|
{
|
||||||
|
@ -104,6 +105,7 @@ int main(int argc, char *argv[])
|
||||||
|
|
||||||
default: printf("Unknown cmd=%02x\n", buf[4]);
|
default: printf("Unknown cmd=%02x\n", buf[4]);
|
||||||
}
|
}
|
||||||
|
if (n < 0) {printf("Write failed - n = %d\n", n); }
|
||||||
}
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Ładowanie…
Reference in New Issue