Skip to content

Commit

Permalink
Update EX-IOExpander copyright
Browse files Browse the repository at this point in the history
  • Loading branch information
peteGSX committed Jan 18, 2024
1 parent bc37a2d commit 657c08c
Showing 1 changed file with 8 additions and 7 deletions.
15 changes: 8 additions & 7 deletions IO_EXIOExpander.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/*
* © 2022, Peter Cole. All rights reserved.
* © 2022, Harald Barth. All rights reserved.
*
* This file is part of EX-CommandStation
*
Expand Down Expand Up @@ -101,13 +102,13 @@ class EXIOExpander : public IODevice {
// Not enough space, free any existing buffer and allocate a new one
if (_digitalPinBytes > 0) free(_digitalInputStates);
if ((_digitalInputStates = (byte*) calloc(digitalBytesNeeded, 1)) != NULL) {
_digitalPinBytes = digitalBytesNeeded;
} else {
DIAG(F("EX-IOExpander I2C:%s ERROR alloc %d bytes"), _I2CAddress.toString(), digitalBytesNeeded);
_deviceState = DEVSTATE_FAILED;
_digitalPinBytes = 0;
return;
}
_digitalPinBytes = digitalBytesNeeded;
} else {
DIAG(F("EX-IOExpander I2C:%s ERROR alloc %d bytes"), _I2CAddress.toString(), digitalBytesNeeded);
_deviceState = DEVSTATE_FAILED;
_digitalPinBytes = 0;
return;
}
}
}

Expand Down

0 comments on commit 657c08c

Please sign in to comment.