diff options
| author | sjaz <sjaz@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-08-06 16:55:33 +0000 |
|---|---|---|
| committer | sjaz <sjaz@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-08-06 16:55:33 +0000 |
| commit | 8d621a71c9fa570f5bbeb6b78855eadaaeb14083 (patch) | |
| tree | fc8e48a314e818291add9395d52d3c1c27867aef | |
| parent | 761d90e1d7633bfd33e4cedf94e5795ac6879b96 (diff) | |
dos2unix a couple more files.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2424 5417fbe8-f217-4b02-8779-1006273d7864
| -rw-r--r-- | lang/langtool.c | 152 | ||||
| -rw-r--r-- | src/nickalias.cpp | 22 |
2 files changed, 87 insertions, 87 deletions
diff --git a/lang/langtool.c b/lang/langtool.c index d54433931..a9244d394 100644 --- a/lang/langtool.c +++ b/lang/langtool.c @@ -1,76 +1,76 @@ -/* Language stuff generator for win32.
- *
- * (C) 2003-2009 Anope Team
- * Contact us at team@anope.org
- *
- * Please read COPYING and README for furhter details.
- *
- * Based on the original code of Epona by Lara.
- * Based on the original code of Services by Andy Church.
- *
- * Written by Dominick Meglio <codemastr@unrealircd.com>
- *
- */
-
-#include <string.h>
-#include <stdio.h>
-#include <cstdlib>
-#include <cctype>
-
-char *strip(char *str)
-{
- char *c;
- if ((c = strchr(str,'\n')))
- *c = 0;
- if ((c = strchr(str,'\r')))
- *c = 0;
- return str;
-}
-
-int main(int argc, char *argv[])
-{
- if (argc < 4)
- exit(1);
-
- /* Build the index file */
- if (!strcmp(argv[1], "index"))
- {
- FILE *fd = fopen(argv[2], "rb");
- FILE *fdout = fopen(argv[3], "wb");
- char buf[1024];
- if (!fd || !fdout)
- exit(2);
-
- while (fgets(buf, 1023, fd))
- {
- if (isupper(*buf))
- fprintf(fdout, "%s", buf);
- }
- fclose(fd);
- fclose(fdout);
- }
- /* Build the language.h file */
- else if (!strcmp(argv[1], "language.h"))
- {
- FILE *fd = fopen(argv[2], "r");
- FILE *fdout = fopen(argv[3], "w");
- char buf[1024];
- int i = 0;
-
- if (!fd || !fdout)
- exit(2);
-
- fprintf(stderr, "Generating language.h... ");
-
- while (fgets(buf, 1023, fd)) {
- fprintf(fdout, "#define %-32s %d\n", strip(buf), i++);
- }
-
- fprintf(fdout, "#define NUM_STRINGS %d\n", i);
- fprintf(stderr, "%d strings\n", i);
- fclose(fd);
- fclose(fdout);
- }
- return 0;
-
-}
+/* Language stuff generator for win32. + * + * (C) 2003-2009 Anope Team + * Contact us at team@anope.org + * + * Please read COPYING and README for furhter details. + * + * Based on the original code of Epona by Lara. + * Based on the original code of Services by Andy Church. + * + * Written by Dominick Meglio <codemastr@unrealircd.com> + * + */ + +#include <string.h> +#include <stdio.h> +#include <cstdlib> +#include <cctype> + +char *strip(char *str) +{ + char *c; + if ((c = strchr(str,'\n'))) + *c = 0; + if ((c = strchr(str,'\r'))) + *c = 0; + return str; +} + +int main(int argc, char *argv[]) +{ + if (argc < 4) + exit(1); + + /* Build the index file */ + if (!strcmp(argv[1], "index")) + { + FILE *fd = fopen(argv[2], "rb"); + FILE *fdout = fopen(argv[3], "wb"); + char buf[1024]; + if (!fd || !fdout) + exit(2); + + while (fgets(buf, 1023, fd)) + { + if (isupper(*buf)) + fprintf(fdout, "%s", buf); + } + fclose(fd); + fclose(fdout); + } + /* Build the language.h file */ + else if (!strcmp(argv[1], "language.h")) + { + FILE *fd = fopen(argv[2], "r"); + FILE *fdout = fopen(argv[3], "w"); + char buf[1024]; + int i = 0; + + if (!fd || !fdout) + exit(2); + + fprintf(stderr, "Generating language.h... "); + + while (fgets(buf, 1023, fd)) { + fprintf(fdout, "#define %-32s %d\n", strip(buf), i++); + } + + fprintf(fdout, "#define NUM_STRINGS %d\n", i); + fprintf(stderr, "%d strings\n", i); + fclose(fd); + fclose(fdout); + } + return 0; + +} diff --git a/src/nickalias.cpp b/src/nickalias.cpp index 2d8817e0c..a8ae405c0 100644 --- a/src/nickalias.cpp +++ b/src/nickalias.cpp @@ -1,11 +1,11 @@ -#include "services.h"
-
-NickAlias::NickAlias()
-{
- next = prev = NULL;
- nick = last_quit = last_realname = last_usermask = NULL;
- time_registered = last_seen = 0;
- status = 0;
- nc = NULL;
-}
-
+#include "services.h" + +NickAlias::NickAlias() +{ + next = prev = NULL; + nick = last_quit = last_realname = last_usermask = NULL; + time_registered = last_seen = 0; + status = 0; + nc = NULL; +} + |
