diff options
authorNeels Hofmeyr <neels@hofmeyr.de>2018-12-06 00:40:37 +0100
committerNeels Hofmeyr <neels@hofmeyr.de>2018-12-10 13:18:38 +0100
commit6aa20eee29846fd86b2ac9c79948d466794cfe68 (patch)
parent496862818d2feabcac926a94a6be2d42826ab19f (diff)
api doc: gsm48_mi_to_string(): warn of return value implementation
1 files changed, 4 insertions, 1 deletions
diff --git a/src/gsm/gsm48.c b/src/gsm/gsm48.c
index ae9a1cf6..e684a3ca 100644
--- a/src/gsm/gsm48.c
+++ b/src/gsm/gsm48.c
@@ -643,7 +643,10 @@ int gsm48_generate_mid_from_imsi(uint8_t *buf, const char *imsi)
* \param[in] str_len Length of \a string in bytes
* \param[in] mi Mobile Identity to be stringified
* \param[in] mi_len Length of \a mi in bytes
- * \returns length of string written to \a string */
+ * \returns WARNING: the return value of this function is not well implemented.
+ * Depending on the MI type and amount of output buffer, this may return
+ * the nr of written bytes, or the written strlen(), or the snprintf()
+ * style strlen()-if-the-buffer-were-large-enough. */
int gsm48_mi_to_string(char *string, const int str_len, const uint8_t *mi,
const int mi_len)