summaryrefslogtreecommitdiffstats
path: root/openbsc
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@gnumonks.org>2011-04-11 16:32:47 +0200
committerHarald Welte <laforge@gnumonks.org>2011-04-12 21:50:46 +0200
commit0d20b635749dea8f056245f283ce571e65d8c2c7 (patch)
treef098d81654ae203a4f0810465f585f1727131084 /openbsc
parent81863cde8253b406e6f544938a1dd996d78c3825 (diff)
libabis: ipaccess: more robust ipaccess_idtag_name()
ipaccess_idtag_name() now takes a uint8_t as parameter which is the length of the type tag. This patch was suggested by Zecke.
Diffstat (limited to 'openbsc')
-rw-r--r--openbsc/include/openbsc/ipaccess.h2
-rw-r--r--openbsc/src/libabis/input/ipaccess.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/openbsc/include/openbsc/ipaccess.h b/openbsc/include/openbsc/ipaccess.h
index 00642ff03..0edd81d81 100644
--- a/openbsc/include/openbsc/ipaccess.h
+++ b/openbsc/include/openbsc/ipaccess.h
@@ -79,7 +79,7 @@ int ipaccess_send_pong(int fd);
int ipaccess_send_id_ack(int fd);
int ipaccess_send_id_req(int fd);
-const char *ipaccess_idtag_name(int tag);
+const char *ipaccess_idtag_name(uint8_t tag);
int ipaccess_idtag_parse(struct tlv_parsed *dec, unsigned char *buf, int len);
int ipaccess_parse_unitid(const char *str, u_int16_t *site_id, u_int16_t *bts_id, u_int16_t *trx_id);
diff --git a/openbsc/src/libabis/input/ipaccess.c b/openbsc/src/libabis/input/ipaccess.c
index e1e314b9b..c4c13d7fa 100644
--- a/openbsc/src/libabis/input/ipaccess.c
+++ b/openbsc/src/libabis/input/ipaccess.c
@@ -100,7 +100,7 @@ static const char *idtag_names[] = {
[IPAC_IDTAG_UNIT] = "Unit_ID",
};
-const char *ipaccess_idtag_name(int tag)
+const char *ipaccess_idtag_name(uint8_t tag)
{
if (tag >= ARRAY_SIZE(idtag_names))
return "unknown";