aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/include/openbsc/oap_messages.h
diff options
context:
space:
mode:
authorHarald Welte <laforge@gnumonks.org>2016-04-27 18:21:16 +0200
committerHarald Welte <laforge@gnumonks.org>2016-04-29 13:10:37 +0200
commit5d547a4358edbd18744d1996d6ecb40328f09061 (patch)
tree866489ca9f7ec7be7ee8016e41680d61a819bb29 /openbsc/include/openbsc/oap_messages.h
parentd8aa412c46638abea05488ebb2e9d70ca7fd628a (diff)
osmo_oap_decode(): Use common argument ordering
In general, if a function generates output data like a msgb (or in this case filling an osmo_oap_message structure), the output argument precedes the source. This is what we use all over libosmo*, and it is modelled after memcpy(), where dst is the first argument, before src. Let's align osmo_oap_decode(). Intestingly, osmo_oap_encode was already correct, so the encode/decode functions used different conventions before.
Diffstat (limited to 'openbsc/include/openbsc/oap_messages.h')
-rw-r--r--openbsc/include/openbsc/oap_messages.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/openbsc/include/openbsc/oap_messages.h b/openbsc/include/openbsc/oap_messages.h
index 496a6de88..ecb66df34 100644
--- a/openbsc/include/openbsc/oap_messages.h
+++ b/openbsc/include/openbsc/oap_messages.h
@@ -64,7 +64,7 @@ struct osmo_oap_message {
uint8_t auts[16];
};
-int osmo_oap_decode(const uint8_t *data, size_t data_len,
- struct osmo_oap_message *oap_msg);
+int osmo_oap_decode(struct osmo_oap_message *oap_msg,
+ const uint8_t *data, size_t data_len);
void osmo_oap_encode(struct msgb *msg, const struct osmo_oap_message *oap_msg);