Git works better when changes are not made when renaming.
authorThadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Thu, 4 Jun 2009 14:14:06 +0000 (11:14 -0300)
committerThadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Thu, 4 Jun 2009 14:17:16 +0000 (11:17 -0300)
This commit will not build, but it will allow us to track the history of
some renamed files better.

improxy.c [deleted file]
improxy.conf [deleted file]
popproxy.c [new file with mode: 0644]
popproxy.conf [new file with mode: 0644]

diff --git a/improxy.c b/improxy.c
deleted file mode 100644 (file)
index b13c49a..0000000
--- a/improxy.c
+++ /dev/null
@@ -1,93 +0,0 @@
-/*
-** Copyright (C) 2006 Thadeu Lima de Souza Cascardo <cascardo@minaslivre.org>
-** Copyright (C) 2009 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
-**  
-** This program 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 2 of the License, or
-** (at your option) any later version.
-**  
-** This program 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 this program; if not, write to the Free Software
-** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
-**  
-*/
-
-#include <glib.h>
-#include <gnet.h>
-#include <stdio.h>
-#include <unistd.h>
-#include "log.h"
-#include "nethook.h"
-#include "proto_detect.h"
-
-#define CONFFILE SYSCONFDIR "/improxy.conf"
-
-void new_client (GServer* server, GConn* conn, gpointer data)
-{
-  net_hook_t* hook;
-  if (conn == NULL)
-    {
-      g_critical ("Server has received an error event.");
-      return;
-    }
-  g_message ("Received connection from %s.", conn->hostname);
-  hook = proto_detect_new (conn);
-  gnet_conn_read (conn);
-}
-
-static gchar* configfile;
-
-static GOptionEntry opt_entries[] =
-  {
-    { "config-file", 'c', 0, G_OPTION_ARG_FILENAME, &configfile,
-      "Configuration file location", "file" },
-    { NULL }
-  };
-
-int main (int argc, char** argv)
-{
-
-  GOptionContext* opt_ctx;
-  GKeyFile *keyfile;
-  GInetAddr* inetaddr;
-  gchar* conf_address;
-  gint port;
-
-  gnet_init ();
-  im_log_init ();
-
-  configfile = CONFFILE;
-  opt_ctx = g_option_context_new ("");
-  g_option_context_add_main_entries (opt_ctx, opt_entries, NULL);
-  if (!g_option_context_parse (opt_ctx, &argc, &argv, NULL))
-    {
-      g_log (NULL, G_LOG_LEVEL_WARNING | G_LOG_FLAG_FATAL,
-            "Could not parse command line options.");
-    }
-  g_option_context_free (opt_ctx);
-  
-  keyfile =  g_key_file_new ();
-
-  g_key_file_load_from_file (keyfile, configfile, G_KEY_FILE_NONE, NULL);
-
-  conf_address = g_key_file_get_string (keyfile, "global", "address", NULL);
-  port = g_key_file_get_integer (keyfile, "global", "port", NULL);
-
-  g_message ("Listen address is %s:%d.", conf_address, port);
-
-  inetaddr = gnet_inetaddr_new_nonblock (conf_address, port);
-  gnet_server_new (inetaddr, port, new_client, NULL);
-
-  daemon (0, 0);
-
-  g_main_loop_run (g_main_loop_new (g_main_context_default (), TRUE));
-
-  return 0;
-
-}
diff --git a/improxy.conf b/improxy.conf
deleted file mode 100644 (file)
index 4bf9862..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-[global]
-
-address = 0.0.0.0
-port = 5222
diff --git a/popproxy.c b/popproxy.c
new file mode 100644 (file)
index 0000000..b13c49a
--- /dev/null
@@ -0,0 +1,93 @@
+/*
+** Copyright (C) 2006 Thadeu Lima de Souza Cascardo <cascardo@minaslivre.org>
+** Copyright (C) 2009 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
+**  
+** This program 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 2 of the License, or
+** (at your option) any later version.
+**  
+** This program 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 this program; if not, write to the Free Software
+** Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+**  
+*/
+
+#include <glib.h>
+#include <gnet.h>
+#include <stdio.h>
+#include <unistd.h>
+#include "log.h"
+#include "nethook.h"
+#include "proto_detect.h"
+
+#define CONFFILE SYSCONFDIR "/improxy.conf"
+
+void new_client (GServer* server, GConn* conn, gpointer data)
+{
+  net_hook_t* hook;
+  if (conn == NULL)
+    {
+      g_critical ("Server has received an error event.");
+      return;
+    }
+  g_message ("Received connection from %s.", conn->hostname);
+  hook = proto_detect_new (conn);
+  gnet_conn_read (conn);
+}
+
+static gchar* configfile;
+
+static GOptionEntry opt_entries[] =
+  {
+    { "config-file", 'c', 0, G_OPTION_ARG_FILENAME, &configfile,
+      "Configuration file location", "file" },
+    { NULL }
+  };
+
+int main (int argc, char** argv)
+{
+
+  GOptionContext* opt_ctx;
+  GKeyFile *keyfile;
+  GInetAddr* inetaddr;
+  gchar* conf_address;
+  gint port;
+
+  gnet_init ();
+  im_log_init ();
+
+  configfile = CONFFILE;
+  opt_ctx = g_option_context_new ("");
+  g_option_context_add_main_entries (opt_ctx, opt_entries, NULL);
+  if (!g_option_context_parse (opt_ctx, &argc, &argv, NULL))
+    {
+      g_log (NULL, G_LOG_LEVEL_WARNING | G_LOG_FLAG_FATAL,
+            "Could not parse command line options.");
+    }
+  g_option_context_free (opt_ctx);
+  
+  keyfile =  g_key_file_new ();
+
+  g_key_file_load_from_file (keyfile, configfile, G_KEY_FILE_NONE, NULL);
+
+  conf_address = g_key_file_get_string (keyfile, "global", "address", NULL);
+  port = g_key_file_get_integer (keyfile, "global", "port", NULL);
+
+  g_message ("Listen address is %s:%d.", conf_address, port);
+
+  inetaddr = gnet_inetaddr_new_nonblock (conf_address, port);
+  gnet_server_new (inetaddr, port, new_client, NULL);
+
+  daemon (0, 0);
+
+  g_main_loop_run (g_main_loop_new (g_main_context_default (), TRUE));
+
+  return 0;
+
+}
diff --git a/popproxy.conf b/popproxy.conf
new file mode 100644 (file)
index 0000000..4bf9862
--- /dev/null
@@ -0,0 +1,4 @@
+[global]
+
+address = 0.0.0.0
+port = 5222