# HG changeset patch # User Eric Warmenhoven # Date 960060631 0 # Node ID b573f33c5e0e22a99ed4dcb136f164d4d7a766fb # Parent f3c8d79688db6588681a8a7ad3eb26d4ff445ea0 [gaim-migrate @ 342] James Nicolson pointed out a potential segfault if the server sends back CONFIG and not CONFIG:toc_whatever... committer: Tailor Script diff -r f3c8d79688db -r b573f33c5e0e src/toc.c --- a/src/toc.c Sat Jun 03 07:25:42 2000 +0000 +++ b/src/toc.c Sat Jun 03 19:30:31 2000 +0000 @@ -877,6 +877,8 @@ /* skip "CONFIG:" (if it exists)*/ + if (config != NULL) { + c = strncmp(config + sizeof(struct sflap_hdr),"CONFIG:",strlen("CONFIG:"))? strtok(config, "\n"): strtok(config + sizeof(struct sflap_hdr)+strlen("CONFIG:"), "\n"); @@ -912,6 +914,8 @@ serv_add_buddies(bud); serv_set_permit_deny(); + } + /* perhaps the server dropped the buddy list, try importing from cache */