laforge has uploaded this change for review. (
https://gerrit.osmocom.org/c/osmo-remsim/+/31182 )
Change subject: bankd_main: Avoid uninitialized variable
......................................................................
bankd_main: Avoid uninitialized variable
There's not really any ResultCode for the kind of error we encounter,
but sending some uninitialized memory clearly is not the right way
either.
>> CID 307528: Uninitialized variables
(UNINIT)
>> Using uninitialized value "res".
Closes: CID#307528
Change-Id: I29f911cb2c8ad67cf1ce4486e1583612fb0b98a6
---
M src/bankd/bankd_main.c
1 file changed, 1 insertion(+), 0 deletions(-)
git pull ssh://gerrit.osmocom.org:29418/osmo-remsim refs/changes/82/31182/1
diff --git a/src/bankd/bankd_main.c b/src/bankd/bankd_main.c
index 90b05d8..e002b94 100644
--- a/src/bankd/bankd_main.c
+++ b/src/bankd/bankd_main.c
@@ -716,6 +716,7 @@
if (worker->state != BW_ST_CONN_WAIT_ID) {
LOGW(worker, "Unexpected connectClientReq\n");
+ res = ResultCode_illegalClientId;
rc = -102;
goto respond_and_err;
}
--
To view, visit
https://gerrit.osmocom.org/c/osmo-remsim/+/31182
To unsubscribe, or for help writing mail filters, visit
https://gerrit.osmocom.org/settings
Gerrit-Project: osmo-remsim
Gerrit-Branch: master
Gerrit-Change-Id: I29f911cb2c8ad67cf1ce4486e1583612fb0b98a6
Gerrit-Change-Number: 31182
Gerrit-PatchSet: 1
Gerrit-Owner: laforge <laforge(a)osmocom.org>
Gerrit-MessageType: newchange