summaryrefslogtreecommitdiffstats
path: root/libs
diff options
context:
space:
mode:
authorEvan Lojewski <github@meklort.com>2020-04-04 16:47:25 -0600
committerGitHub <noreply@github.com>2020-04-04 16:47:25 -0600
commit51053dc2618ddc2a3b04041137e6028128274991 (patch)
tree7b5e805ba85ca16c47809073933f1c1aa7308db1 /libs
parentba1fb59a5a20678073cb1c92e3c6e81a97cc6462 (diff)
downloadbcm5719-ortega-51053dc2618ddc2a3b04041137e6028128274991.tar.gz
bcm5719-ortega-51053dc2618ddc2a3b04041137e6028128274991.zip
ncsi: Fix channle comparison to use actual number of channels supported. (#71)
Diffstat (limited to 'libs')
-rw-r--r--libs/NCSI/ncsi.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/libs/NCSI/ncsi.c b/libs/NCSI/ncsi.c
index b2a5c9c..6a156fc 100644
--- a/libs/NCSI/ncsi.c
+++ b/libs/NCSI/ncsi.c
@@ -233,7 +233,6 @@ NetworkFrame_t gVersionFrame =
typedef struct
{
bool selected;
- int numChannels;
NetworkPort_t *port;
} package_state_t;
@@ -597,7 +596,7 @@ void handleNCSIFrame(NetworkFrame_t *frame)
NCSI_RESPONSE_CODE_COMMAND_FAILED, NCSI_REASON_CODE_INVALID_PAYLOAD_LENGTH);
}
else if ((handler->packageCommand && ch == CHANNEL_ID_PACKAGE) || // Package commands are always accepted.
- (handler->ignoreInit && ch < gPackageState.numChannels))
+ (handler->ignoreInit && ch < NUM_CHANNELS))
{
// Package command. Must handle.
debug("[%x] packageCommand/ignore init channel: %d\n", command, ch);
OpenPOWER on IntegriCloud