comparison src/blist.c @ 5435:a2f26666de42

[gaim-migrate @ 5817] Phroggie says windows doesn't have a z modifier, so I'm just going to change size_t to an int, since it really doesn't matter. I also changed some sprintf's to snprintf's, I'm not really sure why. Changed a printf to gaim_debug in oscar.c, I don't know how that got in there. And I applied a patch that adds an optional callback thing for when a connection is closed. Gaim doesn't use it, but the guy that submitted the patch said it was useful to him. committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Sun, 18 May 2003 19:13:21 +0000
parents 08a90a9e28e4
children ad445074d239
comparison
equal deleted inserted replaced
5434:3034e83c1a49 5435:a2f26666de42
1111 char *g_screenname = get_screenname_filename(account->username); 1111 char *g_screenname = get_screenname_filename(account->username);
1112 char *file = gaim_user_dir(); 1112 char *file = gaim_user_dir();
1113 int protocol = (account->protocol == GAIM_PROTO_OSCAR) ? (isalpha(account->username[0]) ? GAIM_PROTO_TOC : GAIM_PROTO_ICQ): account->protocol; 1113 int protocol = (account->protocol == GAIM_PROTO_OSCAR) ? (isalpha(account->username[0]) ? GAIM_PROTO_TOC : GAIM_PROTO_ICQ): account->protocol;
1114 1114
1115 if (file != (char *)NULL) { 1115 if (file != (char *)NULL) {
1116 sprintf(path, "%s" G_DIR_SEPARATOR_S "%s.%d.blist", file, g_screenname, protocol); 1116 snprintf(path, PATHSIZE, "%s" G_DIR_SEPARATOR_S "%s.%d.blist", file, g_screenname, protocol);
1117 g_free(g_screenname); 1117 g_free(g_screenname);
1118 } else { 1118 } else {
1119 g_free(g_screenname); 1119 g_free(g_screenname);
1120 return; 1120 return;
1121 } 1121 }