summary refs log tree commit diff
path: root/bounce.h
diff options
context:
space:
mode:
Diffstat (limited to 'bounce.h')
-rw-r--r--bounce.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/bounce.h b/bounce.h
index fd64a27..7b9f4f8 100644
--- a/bounce.h
+++ b/bounce.h
@@ -32,24 +32,24 @@
 bool verbose;
 
 enum { ParamCap = 15 };
-struct Command {
+struct Message {
 	const char *origin;
-	const char *name;
+	const char *cmd;
 	const char *params[ParamCap];
 };
 
-static inline struct Command parse(char *line) {
-	struct Command cmd = {0};
-	if (line[0] == ':') cmd.origin = 1 + strsep(&line, " ");
-	cmd.name = strsep(&line, " ");
+static inline struct Message parse(char *line) {
+	struct Message msg = {0};
+	if (line[0] == ':') msg.origin = 1 + strsep(&line, " ");
+	msg.cmd = strsep(&line, " ");
 	for (size_t i = 0; line && i < ParamCap; ++i) {
 		if (line[0] == ':') {
-			cmd.params[i] = &line[1];
+			msg.params[i] = &line[1];
 			break;
 		}
-		cmd.params[i] = strsep(&line, " ");
+		msg.params[i] = strsep(&line, " ");
 	}
-	return cmd;
+	return msg;
 }
 
 void listenConfig(const char *cert, const char *priv);
td>Handle PART and QUIT without messagesJune McEnroe 2018-08-07Make safe filling the who bufferJune McEnroe 2018-08-07Add reverse and reset IRC formatting codesJune McEnroe 2018-08-06Rewrite line editing again, add formattingJune McEnroe 2018-08-06Fix allocation size in vaswprintfJune McEnroe 2018-08-06Implement word wrappingJune McEnroe 2018-08-06Use wchar_t strings for all of UIJune McEnroe 2018-08-06Rename line editing functionsJune McEnroe 2018-08-05Initialize all possible color pairsJune McEnroe 2018-08-05Refactor color initializationJune McEnroe 2018-08-05Add ^L redrawJune McEnroe 2018-08-05Use 16 colors if availableJune McEnroe 2018-08-05Limit parsed colors to number of mIRC colorsJune McEnroe 2018-08-04Show source link on exitJune McEnroe 2018-08-04Implement line editing, scrollingJune McEnroe 2018-08-04Handle /topicJune McEnroe