From 5cf4beec7a00580c2d9b975075ae38edf0886c18 Mon Sep 17 00:00:00 2001 From: Curtis McEnroe Date: Mon, 16 Sep 2019 17:41:18 -0400 Subject: Remove -W WEBIRC option --- catgirl.1 | 25 +------------------------ chat.c | 3 +-- chat.h | 1 - irc.c | 11 ----------- 4 files changed, 2 insertions(+), 38 deletions(-) diff --git a/catgirl.1 b/catgirl.1 index 27b103b..f0f1422 100644 --- a/catgirl.1 +++ b/catgirl.1 @@ -9,7 +9,6 @@ .Sh SYNOPSIS .Nm .Op Fl NPRv -.Op Fl W Ar pass .Op Fl a Ar auth .Op Fl h Ar host .Op Fl j Ar chan @@ -44,15 +43,6 @@ Restrict the use of the .Ic /raw commands. . -.It Fl W Ar pass -Send -.Cm WEBIRC -command with -.Ar pass . -See -.Sx ENVIRONMENT -for details. -. .It Fl a Ar auth Authenticate with SASL PLAIN. .Ar auth @@ -350,20 +340,7 @@ Scroll window up by one line. .El . .Sh ENVIRONMENT -.Bl -tag -width SSH_CLIENT -.It Ev SSH_CLIENT -If -.Fl W -is passed and -.Ev SSH_CLIENT -is set, -the -.Cm WEBIRC -command is used -to set the hostname -to the first word of -.Ev SSH_CLIENT , -usually the client IP address. +.Bl -tag -width Ds .It Ev USER The default nickname. .El diff --git a/chat.c b/chat.c index 7e1a9aa..b3e4b58 100644 --- a/chat.c +++ b/chat.c @@ -53,12 +53,11 @@ int main(int argc, char *argv[]) { setlocale(LC_CTYPE, ""); int opt; - while (0 < (opt = getopt(argc, argv, "NPRW:a:h:j:k:l:n:p:r:u:vw:"))) { + while (0 < (opt = getopt(argc, argv, "NPRa:h:j:k:l:n:p:r:u:vw:"))) { switch (opt) { break; case 'N': self.notify = true; break; case 'P': self.nick = prompt("Name: "); break; case 'R': self.limit = true; - break; case 'W': self.webp = dupe(optarg); break; case 'a': self.auth = dupe(optarg); break; case 'h': self.host = dupe(optarg); break; case 'j': self.join = dupe(optarg); diff --git a/chat.h b/chat.h index 9cec917..e33ea2f 100644 --- a/chat.h +++ b/chat.h @@ -38,7 +38,6 @@ struct { char *port; char *auth; char *pass; - char *webp; char *nick; char *user; char *real; diff --git a/irc.c b/irc.c index 45c1a68..66ffddb 100644 --- a/irc.c +++ b/irc.c @@ -74,17 +74,6 @@ int ircConnect(void) { error = tls_connect_socket(client, sock, self.host); if (error) errx(EX_PROTOCOL, "tls_connect: %s", tls_error(client)); - const char *ssh = getenv("SSH_CLIENT"); - if (self.webp && ssh) { - int len = strlen(ssh); - const char *sp = strchr(ssh, ' '); - if (sp) len = sp - ssh; - ircFmt( - "WEBIRC %s %s %.*s %.*s\r\n", - self.webp, self.user, len, ssh, len, ssh - ); - } - if (self.auth) ircFmt("CAP REQ :sasl\r\n"); if (self.pass) ircFmt("PASS :%s\r\n", self.pass); ircFmt("NICK %s\r\n", self.nick); -- cgit 1.4.1