treewide: tweak includes

Categorize includes by:
* (library includes)
* Osmocom includes except for OsmoBSCNAT
* OsmoBSCNAT includes

Order the includes in each category alphabetically, and remove empty
lines between them. This allows me to keep them consistent, and with
empty lines removed between these categories it doesn't look
inconsistent if there is only one include from two categories in one
file, but multiple includes from the same category in another file.

While at it, also have one empty line after the license header in all
c, h files, and one after the includes.

Related: SYS#5560
Change-Id: I1a7b95ccb0c87fd53645c72f0c02449e8403043b
This commit is contained in:
Oliver Smith 2022-03-09 15:32:03 +01:00
parent f0a26d8ecc
commit 122beff8bb
8 changed files with 6 additions and 16 deletions

View File

@ -16,12 +16,12 @@
* along with this program. If not, see <http://www.gnu.org/lienses/>.
*
*/
#pragma once
#include <osmocom/core/fsm.h>
#include <osmocom/sigtran/sccp_sap.h>
struct bsc_nat_sccp_inst {
uint32_t ss7_id;
struct osmo_ss7_instance *ss7_inst;

View File

@ -16,6 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/lienses/>.
*
*/
#pragma once
void bsc_nat_fsm_alloc(struct bsc_nat *bsc_nat);

View File

@ -16,6 +16,7 @@
* along with this program. If not, see <http://www.gnu.org/lienses/>.
*
*/
#pragma once
#include <osmocom/core/logging.h>

View File

@ -18,7 +18,6 @@
*/
#include "config.h"
#include <osmocom/core/talloc.h>
#include <osmocom/core/utils.h>
#include <osmocom/bsc_nat/bsc_nat.h>

View File

@ -18,18 +18,13 @@
*/
#include "config.h"
#include <errno.h>
#include <stdint.h>
#include <osmocom/core/fsm.h>
#include <osmocom/core/select.h>
#include <osmocom/gsm/gsm0808.h>
#include <osmocom/sigtran/osmo_ss7.h>
#include <osmocom/sigtran/sccp_helpers.h>
#include <osmocom/bsc_nat/bsc_nat.h>
#include <osmocom/bsc_nat/bsc_nat_fsm.h>
#include <osmocom/bsc_nat/logging.h>

View File

@ -16,9 +16,9 @@
* along with this program. If not, see <http://www.gnu.org/lienses/>.
*
*/
#include <osmocom/core/logging.h>
#include <osmocom/core/utils.h>
#include <osmocom/bsc_nat/logging.h>
static const struct log_info_cat log_cat[] = {

View File

@ -18,9 +18,7 @@
*/
#include "config.h"
#include <getopt.h>
#include <osmocom/core/application.h>
#include <osmocom/sigtran/osmo_ss7.h>
#include <osmocom/sigtran/sccp_sap.h>
@ -29,7 +27,6 @@
#include <osmocom/vty/misc.h>
#include <osmocom/vty/ports.h>
#include <osmocom/vty/telnet_interface.h>
#include <osmocom/bsc_nat/bsc_nat.h>
#include <osmocom/bsc_nat/bsc_nat_fsm.h>
#include <osmocom/bsc_nat/logging.h>

View File

@ -18,13 +18,10 @@
*/
#include "config.h"
#include <unistd.h>
#include <osmocom/vty/telnet_interface.h>
#include <osmocom/vty/logging.h>
#include <osmocom/vty/command.h>
#include <osmocom/vty/logging.h>
#include <osmocom/vty/telnet_interface.h>
#include <osmocom/bsc_nat/bsc_nat.h>
#include <osmocom/bsc_nat/vty.h>