From c5bf41e4c8ba513602e835c50ea815d6cc9de335 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sat, 10 Aug 2013 13:02:52 -0400 Subject: Added Makefile --- main.cpp | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'main.cpp') diff --git a/main.cpp b/main.cpp index 99f8cad..1ef7833 100644 --- a/main.cpp +++ b/main.cpp @@ -20,7 +20,11 @@ * */ -char* hostname, nick, port, password, channel; +char* hostname; +char* nick; +int port; +char* password; +char* channel; char* _(const char* str) { @@ -32,8 +36,6 @@ char* _(const char* str) int message(char* params, irc_reply_data* hostd, void* conn) { std::string str(params); - std::string thetime(asctime(gettime())); - thetime = thetime.substr(4,15); if (*hostd->target != '#') { @@ -62,12 +64,11 @@ void terminate(int param) int main(int argc, char** argv) { - atexit(end_logging); signal(SIGTERM, terminate); YAML::Node config = YAML::LoadFile("config.yml"); hostname = _(config["hostname"].as().c_str()); - port = _(config["port"].as().c_str()); + port = config["port"].as(); nick = _(config["nick"].as().c_str()); password = _(config["password"].as().c_str()); channel = _(config["password"].as().c_str()); -- cgit 1.4.1