about summary refs log tree commit diff
path: root/chat.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--chat.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/chat.c b/chat.c
index b966fd1..9325bb6 100644
--- a/chat.c
+++ b/chat.c
@@ -55,17 +55,19 @@ static char *prompt(const char *prompt) {
 int main(int argc, char *argv[]) {
 	char *host = NULL;
 	const char *port = "6697";
-	const char *webPass = NULL;
+	const char *pass = NULL;
+	const char *webirc = NULL;
 
 	int opt;
-	while (0 < (opt = getopt(argc, argv, "h:j:n:p:vw:"))) {
+	while (0 < (opt = getopt(argc, argv, "W:h:j:n:p:vw:"))) {
 		switch (opt) {
+			break; case 'W': webirc = optarg;
 			break; case 'h': host = strdup(optarg);
 			break; case 'j': chat.chan = strdup(optarg);
 			break; case 'n': chat.nick = strdup(optarg);
 			break; case 'p': port = optarg;
 			break; case 'v': chat.verbose = true;
-			break; case 'w': webPass = optarg;
+			break; case 'w': pass = optarg;
 			break; default:  return EX_USAGE;
 		}
 	}
@@ -82,7 +84,7 @@ int main(int argc, char *argv[]) {
 	uiLog(L"Traveling...");
 	uiDraw();
 
-	int sock = ircConnect(host, port, webPass);
+	int sock = ircConnect(host, port, pass, webirc);
 	free(host);
 
 	struct pollfd fds[2] = {
d63741e49980a27e0f009c9042b&follow=1'>Elaborate hi man pageJune McEnroe 2019-02-08Use set for parent in hiJune McEnroe 2019-02-08Switch back to semantic keyword grouping in hiJune McEnroe 2019-02-08Match only the basename in hiJune McEnroe 2019-02-07Add mdoc syntax to hiJune McEnroe 2019-02-07Support multi-line C macros in hiJune McEnroe 2019-02-07Detect .mk files as makeJune McEnroe 2019-02-07Add make syntax to hiJune McEnroe 2019-02-07Add IRC output to hiJune McEnroe 2019-02-07Improve C syntax accuracy and add Format classJune McEnroe 2019-02-07Factor out hi checkJune McEnroe Fix subexpression bounds check and compile pattends. 2019-02-07Add Escape class to hiJune McEnroe 2019-02-07Add Todo class and parent syntax constraintJune McEnroe