+int faimtest_flapversion(struct aim_session_t *sess, struct command_rx_struct *command, ...)
+{
+
+ printf("faimtest: using FLAP version %u\n", aimutil_get32(command->data));
+
+#if 0
+ /*
+ * This is an alternate location for starting the login process.
+ */
+ /* XXX should do more checking to make sure its really the right AUTH conn */
+ if (command->conn->type == AIM_CONN_TYPE_AUTH) {
+ /* do NOT send a connack/flapversion, request_login will send it if needed */
+ aim_request_login(sess, command->conn, screenname);
+ printf("faimtest: login request sent\n");
+ }
+#endif
+
+ return 1;
+}
+
+/*
+ * This is a frivilous callback. You don't need it. I only used it for
+ * debugging non-blocking connects.
+ *
+ * If packets are sent to a conn before its fully connected, they
+ * will be queued and then transmitted when the connection completes.
+ *
+ */
+int faimtest_conncomplete(struct aim_session_t *sess, struct command_rx_struct *command, ...)
+{
+ va_list ap;
+ struct aim_conn_t *conn;
+
+ va_start(ap, command);
+ conn = va_arg(ap, struct aim_conn_t *);
+ va_end(ap);
+
+ if (conn)
+ printf("faimtest: connection on %d completed\n", conn->fd);
+
+ return 1;
+}
+