Vadim Yanitskiy has submitted this change and it was merged.

Change subject: src/libmsc/ussd.c: drop useless forward declaration
......................................................................


src/libmsc/ussd.c: drop useless forward declaration

There is no any significant reason to define static function
'send_own_number' after the code that calls it.

Change-Id: I8d804398cfa460eaa5a5f84f0ed90909488d0bdd
---
M openbsc/src/libmsc/ussd.c
1 file changed, 10 insertions(+), 13 deletions(-)

Approvals:
  Max: Looks good to me, but someone else must approve
  Harald Welte: Looks good to me, approved
  Jenkins Builder: Verified



diff --git a/openbsc/src/libmsc/ussd.c b/openbsc/src/libmsc/ussd.c
index f12c1f2..488e813 100644
--- a/openbsc/src/libmsc/ussd.c
+++ b/openbsc/src/libmsc/ussd.c
@@ -37,8 +37,16 @@
 /* Declarations of USSD strings to be recognised */
 const char USSD_TEXT_OWN_NUMBER[] = "*#100#";
 
-/* Forward declarations of network-specific handler functions */
-static int send_own_number(struct gsm_subscriber_connection *conn, const 
struct msgb *msg, const struct ss_request *req);
+/* A network-specific handler function */
+static int send_own_number(struct gsm_subscriber_connection *conn, const 
struct msgb *msg, const struct ss_request *req)
+{
+       char *own_number = conn->subscr->extension;
+       char response_string[GSM_EXTENSION_LENGTH + 20];
+
+       /* Need trailing CR as EOT character */
+       snprintf(response_string, sizeof(response_string), "Your extension is 
%s\r", own_number);
+       return gsm0480_send_ussd_response(conn, msg, response_string, req);
+}
 
 
 /* Entrypoint - handler function common to all mobile-originated USSDs */
@@ -81,15 +89,4 @@
        /* check if we can release it */
        msc_release_connection(conn);
        return rc;
-}
-
-/* A network-specific handler function */
-static int send_own_number(struct gsm_subscriber_connection *conn, const 
struct msgb *msg, const struct ss_request *req)
-{
-       char *own_number = conn->subscr->extension;
-       char response_string[GSM_EXTENSION_LENGTH + 20];
-
-       /* Need trailing CR as EOT character */
-       snprintf(response_string, sizeof(response_string), "Your extension is 
%s\r", own_number);
-       return gsm0480_send_ussd_response(conn, msg, response_string, req);
 }

-- 
To view, visit https://gerrit.osmocom.org/5739
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I8d804398cfa460eaa5a5f84f0ed90909488d0bdd
Gerrit-PatchSet: 2
Gerrit-Project: openbsc
Gerrit-Branch: master
Gerrit-Owner: Vadim Yanitskiy <axilira...@gmail.com>
Gerrit-Reviewer: Harald Welte <lafo...@gnumonks.org>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Max <msur...@sysmocom.de>
Gerrit-Reviewer: Vadim Yanitskiy <axilira...@gmail.com>

Reply via email to