diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/misc.c | 22 | ||||
-rw-r--r-- | src/process.c | 19 |
2 files changed, 16 insertions, 25 deletions
diff --git a/src/misc.c b/src/misc.c index 79182eafb..7b226c148 100644 --- a/src/misc.c +++ b/src/misc.c @@ -787,28 +787,6 @@ char *myStrSubString(const char *src, int start, int end) /*************************************************************************/ -void protocol_debug(char *source, char *cmd, int argc, const char **argv) -{ - int i; - - if (protocoldebug) { - if (source) - alog("debug: Source %s", source); - if (cmd) - alog("debug: Token %s", cmd); - if (argc) { - for (i = 0; i < argc; i++) { - alog("debug: av[%d] = %s", i, argv[i]); - } - } else { - alog("debug: av[0] = NULL"); - } - } - return; -} - -/*************************************************************************/ - /** * Clean up the buffer for extra spaces * @param str to clean up diff --git a/src/process.c b/src/process.c index 8e4201c58..e75b444bc 100644 --- a/src/process.c +++ b/src/process.c @@ -372,9 +372,22 @@ void process() s = buf + strlen(buf); strscpy(cmd, buf, sizeof(cmd)); ac = split_buf(s, &av, 1); - if (protocoldebug) { - protocol_debug(source, cmd, ac, av); - } + + if (protocoldebug) + { + if (*source) + alog("debug: Source %s", source); + if (*cmd) + alog("debug: Token %s", cmd); + if (ac) + { + int i; + for (i = 0; i < ac; i++) + alog("debug: av[%d] = %s", i, av[i]); + } + else + alog("debug: av[0] = NULL"); + } if (mod_current_buffer) { free(mod_current_buffer); |