summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVadim Yanitskiy <axilirator@gmail.com>2020-02-14 16:46:54 +0700
committerSteve Markgraf <steve@steve-m.de>2021-10-23 18:51:19 +0200
commitc4227d4c56e63abf340125fa357e2912291cd43f (patch)
treeecfe88a9c7554542672a2dc5c1bcd6b0d6784737
parent3b9d6f3bbf4f1ab75459763a76437d448ff5fa02 (diff)
layer23/transceiver: fix: always include command arguments in the response
-rw-r--r--src/host/layer23/src/transceiver/trx.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/src/host/layer23/src/transceiver/trx.c b/src/host/layer23/src/transceiver/trx.c
index a8f213c7..5b6214ee 100644
--- a/src/host/layer23/src/transceiver/trx.c
+++ b/src/host/layer23/src/transceiver/trx.c
@@ -271,7 +271,7 @@ _trx_ctrl_cmd_settsc(struct trx *trx, const char *cmd, const char *args)
"TRX received SETTSC command ! "
"OpenBTS should be configured to send SETBSIC command !\n");
- return _trx_ctrl_send_resp(trx, cmd, -1, NULL);
+ return _trx_ctrl_send_resp(trx, cmd, -1, "%s", args);
}
static int
@@ -281,13 +281,12 @@ _trx_ctrl_cmd_setbsic(struct trx *trx, const char *cmd, const char *args)
if (bsic >= 64) {
LOGP(DTRX, LOGL_ERROR, "Invalid BSIC received\n");
- return _trx_ctrl_send_resp(trx, cmd, -1, NULL);
+ return _trx_ctrl_send_resp(trx, cmd, -1, "%d", bsic);
}
trx->bsic = bsic;
- /* FIXME: include the arguments in response */
- return _trx_ctrl_send_resp(trx, cmd, 0, NULL);
+ return _trx_ctrl_send_resp(trx, cmd, 0, "%d", bsic);
}
static int
@@ -508,7 +507,7 @@ _trx_ctrl_read_cb(struct osmo_fd *ofd, unsigned int what)
if (!ch->cmd) {
LOGP(DTRX, LOGL_ERROR, "[!] No handlers found for command '%s'. Empty response\n", cmd);
- _trx_ctrl_send_resp(trx, cmd, -1, NULL);
+ _trx_ctrl_send_resp(trx, cmd, -1, args);
}
/* Done ! */