diff options
-rw-r--r-- | linux/src/api/gates/GateMP.c | 6 | ||||
-rw-r--r-- | linux/src/daemon/GateMP_daemon.c | 6 |
2 files changed, 12 insertions, 0 deletions
diff --git a/linux/src/api/gates/GateMP.c b/linux/src/api/gates/GateMP.c index e71629d..9a0024f 100644 --- a/linux/src/api/gates/GateMP.c +++ b/linux/src/api/gates/GateMP.c @@ -390,6 +390,12 @@ Int GateMP_open(String name, GateMP_Handle *handle) *handle = NULL; status = GateMP_E_NOTFOUND; } + else if (len != sizeof(nsValue)) { + *handle = NULL; + status = GateMP_E_NOTFOUND; + PRINTVERBOSE0("GateMP configuration not valid for hostSupport. " + "Try adding hostSupport to your config if it is needed.\n"); + } else { arg = nsValue[2]; mask = nsValue[3]; diff --git a/linux/src/daemon/GateMP_daemon.c b/linux/src/daemon/GateMP_daemon.c index a7b9210..56b2ad6 100644 --- a/linux/src/daemon/GateMP_daemon.c +++ b/linux/src/daemon/GateMP_daemon.c @@ -513,6 +513,12 @@ static Int GateMP_openDefaultGate(GateMP_Handle *handlePtr, UInt16 procId[]) *handlePtr = NULL; status = GateMP_E_NOTFOUND; } + else if (len != sizeof(nsValue)) { + *handlePtr = NULL; + status = GateMP_E_NOTFOUND; + LOG0("GateMP configuration not valid for hostSupport. " + "Try adding hostSupport to your config if it is needed.\n"); + } else { arg = nsValue[2]; mask = nsValue[3]; |