ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/common/treasure.C
(Generate patch)

Comparing deliantra/server/common/treasure.C (file contents):
Revision 1.14 by pippijn, Thu Sep 7 09:37:12 2006 UTC vs.
Revision 1.15 by root, Sat Sep 9 21:48:28 2006 UTC

1 1
2/* 2/*
3 * static char *rcs_treasure_c = 3 * static char *rcs_treasure_c =
4 * "$Id: treasure.C,v 1.14 2006/09/07 09:37:12 pippijn Exp $"; 4 * "$Id: treasure.C,v 1.15 2006/09/09 21:48:28 root Exp $";
5 */ 5 */
6 6
7/* 7/*
8 CrossFire, A Multiplayer game for X-windows 8 CrossFire, A Multiplayer game for X-windows
9 9
1835} 1835}
1836 1836
1837void 1837void
1838free_artifact (artifact * at) 1838free_artifact (artifact * at)
1839{ 1839{
1840
1841 if (at->next) 1840 if (at->next)
1842 free_artifact (at->next); 1841 free_artifact (at->next);
1842
1843 if (at->allowed) 1843 if (at->allowed)
1844 free_charlinks (at->allowed); 1844 free_charlinks (at->allowed);
1845 1845
1846 delete at->item; 1846 at->item->free (1);
1847 1847
1848 delete at; 1848 delete at;
1849} 1849}
1850 1850
1851void 1851void
1852free_artifactlist (artifactlist * al) 1852free_artifactlist (artifactlist * al)
1853{ 1853{
1854 artifactlist *nextal; 1854 artifactlist *nextal;
1855
1855 for (al = first_artifactlist; al != NULL; al = nextal) 1856 for (al = first_artifactlist; al != NULL; al = nextal)
1856 { 1857 {
1857 nextal = al->next; 1858 nextal = al->next;
1859
1858 if (al->items) 1860 if (al->items)
1859 {
1860 free_artifact (al->items); 1861 free_artifact (al->items);
1861 } 1862
1862 free (al); 1863 free (al);
1863 } 1864 }
1864} 1865}
1865 1866
1866void 1867void

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines