comparison src/protocols/oscar/oscar.c @ 7054:7c04a0775918

[gaim-migrate @ 7617] WinGaim 0.69 moved the gaim settings directory exposing an oscar bug.. What to do if a buddy icon cache copy does not exist but a check sum does. Also moved win32 code to initialize gaim settings dir before core initializations. committer: Tailor Script <tailor@pidgin.im>
author Herman Bloggs <hermanator12002@yahoo.com>
date Tue, 30 Sep 2003 05:36:28 +0000
parents 237ad253dd34
children 9946001989a3
comparison
equal deleted inserted replaced
7053:9d8e56c66854 7054:7c04a0775918
1822 1822
1823 /* Server stored icon stuff */ 1823 /* Server stored icon stuff */
1824 if (info->iconcsumlen) { 1824 if (info->iconcsumlen) {
1825 char *b16, *saved_b16; 1825 char *b16, *saved_b16;
1826 GaimBuddy *b; 1826 GaimBuddy *b;
1827 FILE *file;
1827 1828
1828 b16 = tobase16(info->iconcsum, info->iconcsumlen); 1829 b16 = tobase16(info->iconcsum, info->iconcsumlen);
1829 b = gaim_find_buddy(gc->account, info->sn); 1830 b = gaim_find_buddy(gc->account, info->sn);
1830 saved_b16 = gaim_buddy_get_setting(b, "icon_checksum"); 1831 /* If for some reason the checksum is valid, but cached file is not..
1832 we want to know. */
1833 if((file = fopen(gaim_buddy_get_setting(b, "buddy_icon"), "rb"))) {
1834 fclose(file);
1835 saved_b16 = gaim_buddy_get_setting(b, "icon_checksum");
1836 }
1837 else
1838 saved_b16 = NULL;
1839
1831 if (!b16 || !saved_b16 || strcmp(b16, saved_b16)) { 1840 if (!b16 || !saved_b16 || strcmp(b16, saved_b16)) {
1832 GSList *cur = od->requesticon; 1841 GSList *cur = od->requesticon;
1833 while (cur && aim_sncmp((char *)cur->data, info->sn)) 1842 while (cur && aim_sncmp((char *)cur->data, info->sn))
1834 cur = cur->next; 1843 cur = cur->next;
1835 if (!cur) { 1844 if (!cur) {