view PROGRAMMING_NOTES @ 5124:2e78141ec1b5

[gaim-migrate @ 5487] The change to gaim-remote.c let me compile again. This fixes the proxy problems with AIM and ICQ. Tha Problem: AIM and ICQ accounts would get signed off when receiving large chunks of data that spanned multiple TCP packets. For people with big buddy lists, this meant you would get kicked offline as soon as you signed on (because you buddy list would have to be sent in more than one TCP packet), for other people, you would get kicked offline when receiving someone's buddy icon. The Solution: I checked out about 20 CVS from different times and narrowed the commit to between February 23rd and 27th. I then looked at the commit log for src/protocols/oscar/conn.c between those days and looked for something that might cause problems, and reverted it. The Culprit: Herman's commit on February 25, 2003. It fixed some initite lizooping when connecting to oscar accounts in Windows. http://cvs.sourceforge.net/cgi-bin/viewcvs.cgi/gaim/gaim/src/protocols/oscar/conn.c.diff?r1=1.17&r2=1.18 committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Sun, 13 Apr 2003 22:19:43 +0000
parents 59ff9d0b7b85
children 10b5ac17fdd6
line wrap: on
line source

Notes on keeping GAIM OS independant
------------------------------------

General
-------
- Use G_DIR_SEPARATOR_S and G_DIR_SEPARATOR for paths

- Use g_getenv, g_snprintf, g_vsnprintf

- Use gaim_home_dir instead of g_get_home_dir or g_getenv("HOME")

- Make sure when including win32dep.h that it is the last header to
  be included.

- Open binary files when reading or writing with 'b' mode.

  e.g: fopen("somefile", "wb");

  Not doing so will open files in windows using defaut translation mode. 
  i.e. newline -> <CR><LF>

Paths
-----

- DATADIR, LOCALEDIR & LIBDIR are defined in wingaim as functions.
  Doing the following will therefore break the windows build:

  printf("File in DATADIR is: %s\n", DATADIR G_DIR_SEPARATOR_S "pic.png");

  it should be:

  printf("File in DATADIR is: %s%s%s\n", DATADIR, G_DIR_SEPARATOR_S, "pic.png");

PLUGINS & PROTOS
----------------

- G_MODULE_EXPORT all functions which are to be accessed from outside the
  scope of its "dll" or "so". (E.G. gaim_plugin_init)

- G_MODULE_IMPORT all global variables which are located outside your
  dynamic library. (E.G. connections)

  (Not doing this will cause "Memory Access Violations" in Win32)