chg: remove warning unused variable

This commit is contained in:
Chris 2018-09-09 23:16:47 +02:00
parent d42b4f6ddf
commit 0a648d482d
5 changed files with 6 additions and 7 deletions

View file

@ -1576,7 +1576,7 @@ int CmdLoad(const char *Cmd) {
// set signal properties low/high/mean/amplitude and isnoice detection
uint8_t bits[GraphTraceLen];
size_t size = getFromGraphBuf(bits);
isNoise(bits, sizeof(bits));
isNoise(bits, size);
return 0;
}

View file

@ -242,7 +242,7 @@ int CmdAWIDRead_device(const char *Cmd) {
int CmdAWIDDemod(const char *Cmd) {
uint8_t bits[MAX_GRAPH_TRACE_LEN]={0};
size_t size = getFromGraphBuf(bits);
if (size==0) {
if (size == 0) {
PrintAndLogEx(DEBUG, "DEBUG: Error - AWID not enough samples");
return 0;
}

View file

@ -799,7 +799,6 @@ int EM4x50Read(const char *Cmd, bool verbose) {
uint8_t bits[MAX_GRAPH_TRACE_LEN] = {0};
size_t size = getFromGraphBuf(bits);
isNoise(bits, size);
signal_t *sp = getSignalProperties();

View file

@ -130,7 +130,7 @@ int CmdHIDDemod(const char *Cmd) {
uint8_t bits[MAX_GRAPH_TRACE_LEN] = {0};
size_t size = getFromGraphBuf(bits);
if (size==0) {
if (size == 0) {
PrintAndLogEx(DEBUG, "DEBUG: Error - HID not enough samples");
return 0;
}

View file

@ -538,7 +538,7 @@ bool tryDetectModulation(){
}
} else {
clk = GetAskClock("", false);
if (clk>0) {
if (clk > 0) {
tests[hits].ST = true;
// "0 0 1 " == clock auto, invert false, maxError 1.
// false = no verbose
@ -583,7 +583,7 @@ bool tryDetectModulation(){
}
}
clk = GetNrzClock("", false);
if (clk>8) { //clock of rf/8 is likely a false positive, so don't use it.
if (clk > 8) { //clock of rf/8 is likely a false positive, so don't use it.
if ( NRZrawDemod("0 0 1", false) && test(DEMOD_NRZ, &tests[hits].offset, &bitRate, clk, &tests[hits].Q5)) {
tests[hits].modulation = DEMOD_NRZ;
tests[hits].bitrate = bitRate;
@ -604,7 +604,7 @@ bool tryDetectModulation(){
}
clk = GetPskClock("", false);
if (clk>0) {
if (clk > 0) {
// allow undo
save_restoreGB(GRAPH_SAVE);
// skip first 160 samples to allow antenna to settle in (psk gets inverted occasionally otherwise)