From 750c896b4a9e619bbc6f712f82b8d602a1750f96 Mon Sep 17 00:00:00 2001 From: Vadim Yanitskiy Date: Sat, 9 Sep 2017 14:09:55 +0300 Subject: libosmogapk: rename the 'logging.c' to 'common.c' There are not so much code, related to internal logging subsystem. So, there is no reason to keep a few lines in a dedicated file. In the future one may also be used for other routines. --- src/Makefile.am | 4 ++-- src/common.c | 28 ++++++++++++++++++++++++++++ src/logging.c | 27 --------------------------- 3 files changed, 30 insertions(+), 29 deletions(-) create mode 100644 src/common.c delete mode 100644 src/logging.c diff --git a/src/Makefile.am b/src/Makefile.am index 060d435..8efd165 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -76,9 +76,9 @@ libosmogapk_la_SOURCES += \ benchmark.c \ $(NULL) -# Logging +# Common routines libosmogapk_la_SOURCES += \ - logging.c \ + common.c \ $(NULL) # libosmogapk representative application diff --git a/src/common.c b/src/common.c new file mode 100644 index 0000000..1984d29 --- /dev/null +++ b/src/common.c @@ -0,0 +1,28 @@ +/* + * This file is part of gapk (GSM Audio Pocket Knife). + * + * (C) 2017 by Vadim Yanitskiy + * + * gapk is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * gapk is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with gapk. If not, see . + */ + +/* Internal GAPK logging */ +int osmo_gapk_log_init_complete = 0; +int osmo_gapk_log_subsys; + +void osmo_gapk_log_init(int subsys) +{ + osmo_gapk_log_subsys = subsys; + osmo_gapk_log_init_complete = 1; +} diff --git a/src/logging.c b/src/logging.c deleted file mode 100644 index 96313ae..0000000 --- a/src/logging.c +++ /dev/null @@ -1,27 +0,0 @@ -/* - * This file is part of gapk (GSM Audio Pocket Knife). - * - * (C) 2017 by Vadim Yanitskiy - * - * gapk is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * gapk is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with gapk. If not, see . - */ - -int osmo_gapk_log_init_complete = 0; -int osmo_gapk_log_subsys; - -void osmo_gapk_log_init(int subsys) -{ - osmo_gapk_log_subsys = subsys; - osmo_gapk_log_init_complete = 1; -} -- cgit v1.2.3