(sendcmd): Change argument cmd to string. Callers changed.

(fnlist, fn, USER, COUN, QUIT, PASS, PLAY, LIST, CMD, CTLD, KILL):
Unused, remove.
This commit is contained in:
Markus Armbruster 2005-05-26 13:18:58 +00:00
parent 44b11ab597
commit 801d32783d
9 changed files with 15 additions and 134 deletions

View file

@ -32,7 +32,6 @@
*/
#include "misc.h"
#include "fnlist.h"
#include <stdio.h>
#include <string.h>
@ -140,13 +139,13 @@ expect(int s, int match, char *buf)
}
void
sendcmd(int s, int cmd, char *arg)
sendcmd(int s, char *cmd, char *arg)
{
char buf[128];
int cc;
int len;
(void)sprintf(buf, "%s %s\n", fnlist[cmd].name, arg != NULL ? arg : "");
(void)sprintf(buf, "%s %s\n", cmd, arg != NULL ? arg : "");
len = strlen(buf);
#ifndef _WIN32
cc = write(s, buf, len);