diff libpurple/protocols/irc/cmds.c @ 16425:6447865b2d08

/whowas for IRC. Thanks, achris.
author Ethan Blanton <elb@pidgin.im>
date Wed, 25 Apr 2007 16:03:24 +0000
parents 32c366eeeb99
children 44b4e8bd759b
line wrap: on
line diff
--- a/libpurple/protocols/irc/cmds.c	Wed Apr 25 13:42:00 2007 +0000
+++ b/libpurple/protocols/irc/cmds.c	Wed Apr 25 16:03:24 2007 +0000
@@ -559,6 +559,22 @@
 	return 0;
 }
 
+int irc_cmd_whowas(struct irc_conn *irc, const char *cmd, const char *target, const char **args)
+{
+	char *buf;
+
+	if (!args || !args[0])
+		return 0;
+
+	buf = irc_format(irc, "vn", "WHOWAS", args[0]);
+	
+	irc->whois.nick = g_strdup(args[0]);
+	irc_send(irc, buf);
+	g_free(buf);
+
+	return 0;
+}
+
 static void irc_do_mode(struct irc_conn *irc, const char *target, const char *sign, char **ops)
 {
 	char *buf, mode[5];