replaced local macros with flags

This commit is contained in:
Václav Šmejkal 2023-08-26 18:57:53 +02:00
parent 902872d25c
commit b11f092bda
Signed by: ENGO150
GPG Key ID: 4A57E86482968843
2 changed files with 3 additions and 5 deletions

View File

@ -32,5 +32,6 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
#define WHY2_CHAT_CONFIG_DIR "/home/{USER}/.config/WHY2"
#define WHY2_CHAT_CONFIG_URL "https://raw.githubusercontent.com/ENGO150/WHY2/development/src/chat/"
#define WHY2_CHAT_CONFIG_SERVER "server.yml"
#define WHY2_CHAT_CONFIG_CLIENT "client.yml"
#endif

View File

@ -31,9 +31,6 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
#include <why2/memory.h>
#include <why2/misc.h>
#define SERVER "server.yml"
#define CLIENT "client.yml"
//LOCAL
void init_config(char *filename)
{
@ -74,10 +71,10 @@ void init_config(char *filename)
//GLOBAL
void why2_chat_init_server_config(void)
{
init_config(SERVER);
init_config(WHY2_CHAT_CONFIG_SERVER);
}
void why2_chat_init_client_config(void)
{
init_config(CLIENT);
init_config(WHY2_CHAT_CONFIG_CLIENT);
}