Esp8266_deauther: Interval for continous script run is ignored - fix inside

Created on 10 Jun 2018  路  4Comments  路  Source: SpacehuhnTech/esp8266_deauther

The interval for running a script continuously via "run script.txt -c 60s" is ignored and always set to 10 seconds. This is because line 867 in SerialInterface.cpp contains an error:
if (list->size() == 3) {
It should be:
if (list->size() > 3) {

(if a time interval is given, the size of the liste will be 4, not 3)

bug

All 4 comments

nice catch :clap:
Maybe if (list->size() == 4) would work?
Also this would need to be changed too: continueTime = getTime(list->get(4));

馃槶 serial interface is such a mess. I think I'll redo it after all https://github.com/spacehuhn/esp8266_deauther/issues/846

@tobozo :

Maybe if (list->size() == 4) would work?

That would be less future-proof if we would introduce more parameters for this function. ">3" is in my opinion slightly better.

Also this would need to be changed too: continueTime = getTime(list->get(4));

No, this one is correct with get(3), as that actually gets the fourth element (index starts at 0)

For the upcoming version 3, I'm using SimpleCLI to solve this issue.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

itsik-b picture itsik-b  路  4Comments

sieuwe1 picture sieuwe1  路  4Comments

joneroy picture joneroy  路  3Comments

glblduh picture glblduh  路  3Comments

ghost picture ghost  路  3Comments