about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--chat.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/chat.c b/chat.c
index 09d0ca6..2a64ee0 100644
--- a/chat.c
+++ b/chat.c
@@ -315,6 +315,12 @@ int main(int argc, char *argv[]) {
 	
 	int irc = ircConnect(bind, host, port);
 
+#ifdef __OpenBSD__
+	error = pledge(promisesFinal, NULL);
+	if (error) err(EX_OSERR, "pledge");
+	free(promisesFinal);
+#endif
+
 	if (pass) ircFormat("PASS :%s\r\n", pass);
 	if (sasl) ircFormat("CAP REQ :sasl\r\n");
 	ircFormat("CAP LS\r\n");
@@ -343,12 +349,6 @@ int main(int argc, char *argv[]) {
 		fcntl(execPipe[1], F_SETFD, FD_CLOEXEC);
 	}
 
-#ifdef __OpenBSD__
-	error = pledge(promisesFinal, NULL);
-	if (error) err(EX_OSERR, "pledge");
-	free(promisesFinal);
-#endif
-
 	struct pollfd fds[] = {
 		{ .events = POLLIN, .fd = STDIN_FILENO },
 		{ .events = POLLIN, .fd = irc },
d>Add imbox and notemap to pageJune McEnroe 2020-02-12Collapse simple linksJune McEnroe 2020-02-12Move catgirl up the pageJune McEnroe 2020-02-12Update catgirl pty grabJune McEnroe 2020-02-12Link to cgit /about pages where appropriateJune McEnroe 2020-02-11Separate LINKS from BINS for html to workJune McEnroe 2020-02-11Add margin to Bl-bullet itemsJune McEnroe 2020-02-10Match URLs inside parens or with paired parens insideJune McEnroe 2020-02-10Duplicate effective URL before passing it back to curlJune McEnroe 2020-02-09Add To Be Taught, If FortunateJune McEnroe 2020-02-04Add The Future of Another TimelineJune McEnroe 2020-01-31Reorganize the Makefile for the umpteenth timeJune McEnroe 2020-01-28Change scout sensitivity to 1.4June McEnroe 2020-01-28Import shows.txtJune McEnroe