mirror of
https://github.com/DCC-EX/CommandStation-EX.git
synced 2024-11-24 00:26:13 +01:00
Comments and a reliability fix.
This commit is contained in:
parent
c1a8206667
commit
6737785388
|
@ -1,3 +1,22 @@
|
||||||
|
/*
|
||||||
|
* © 2020, Chris Harlow. All rights reserved.
|
||||||
|
* © 2020, Harald Barth.
|
||||||
|
*
|
||||||
|
* This file is part of Asbelos DCC API
|
||||||
|
*
|
||||||
|
* This is free software: you can redistribute it and/or modify
|
||||||
|
* it under the terms of the GNU General Public License as published by
|
||||||
|
* the Free Software Foundation, either version 3 of the License, or
|
||||||
|
* (at your option) any later version.
|
||||||
|
*
|
||||||
|
* It is distributed in the hope that it will be useful,
|
||||||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
* GNU General Public License for more details.
|
||||||
|
*
|
||||||
|
* You should have received a copy of the GNU General Public License
|
||||||
|
* along with CommandStation. If not, see <https://www.gnu.org/licenses/>.
|
||||||
|
*/
|
||||||
#include <Arduino.h>
|
#include <Arduino.h>
|
||||||
#include "WifiInboundHandler.h"
|
#include "WifiInboundHandler.h"
|
||||||
#include "RingStream.h"
|
#include "RingStream.h"
|
||||||
|
|
|
@ -287,6 +287,7 @@ wifiSerialState WifiInterface::setup2(const FSH* SSid, const FSH* password,
|
||||||
{
|
{
|
||||||
const byte MAX_IP_LENGTH=15;
|
const byte MAX_IP_LENGTH=15;
|
||||||
char ipString[MAX_IP_LENGTH+1];
|
char ipString[MAX_IP_LENGTH+1];
|
||||||
|
ipString[MAX_IP_LENGTH]='\0'; // protection against missing " character on end.
|
||||||
byte ipLen=0;
|
byte ipLen=0;
|
||||||
for(byte ipLen=0;ipLen<MAX_IP_LENGTH;ipLen++) {
|
for(byte ipLen=0;ipLen<MAX_IP_LENGTH;ipLen++) {
|
||||||
while(!wifiStream->available());
|
while(!wifiStream->available());
|
||||||
|
|
Loading…
Reference in New Issue
Block a user