view libfaim/aim_ads.c @ 510:dab0c611029e

[gaim-migrate @ 520] 0.9.21 will never exist, so what about 0.10.0? (Yes, we're slowly approaching 1.0.0) committer: Tailor Script <tailor@pidgin.im>
author Rob Flynn <gaim@robflynn.com>
date Thu, 20 Jul 2000 16:45:21 +0000
parents e4c34ca88d9b
children 595ac7759563
line wrap: on
line source

/*
 *
 *
 */

#include <faim/aim.h>

u_long aim_ads_clientready(struct aim_session_t *sess,
			   struct aim_conn_t *conn)
{
  struct command_tx_struct *newpacket;
  int i;

  if (!(newpacket = aim_tx_new(AIM_FRAMETYPE_OSCAR, 0x0002, conn, 0x1a)))
    return -1;

  newpacket->lock = 1;

  i = aim_putsnac(newpacket->data, 0x0001, 0x0002, 0x0000, sess->snac_nextid);

  i+= aimutil_put16(newpacket->data+i, 0x0001);
  i+= aimutil_put16(newpacket->data+i, 0x0002);

  i+= aimutil_put16(newpacket->data+i, 0x0001);
  i+= aimutil_put16(newpacket->data+i, 0x0013);

  i+= aimutil_put16(newpacket->data+i, 0x0005);
  i+= aimutil_put16(newpacket->data+i, 0x0001);
  i+= aimutil_put16(newpacket->data+i, 0x0001);
  i+= aimutil_put16(newpacket->data+i, 0x0001);

  newpacket->lock = 0;
  aim_tx_enqueue(sess, newpacket);

  return (sess->snac_nextid++);
}

u_long aim_ads_requestads(struct aim_session_t *sess,
			  struct aim_conn_t *conn)
{
  return aim_genericreq_n(sess, conn, 0x0005, 0x0002);
}