diff options
Diffstat (limited to 'hacks/halo.c')
-rw-r--r-- | hacks/halo.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/hacks/halo.c b/hacks/halo.c index 42b6a55..c4d5ada 100644 --- a/hacks/halo.c +++ b/hacks/halo.c @@ -117,6 +117,7 @@ halo_init (Display *dpy, Window window) progname, mode_str); exit (1); } + if (mode_str) free (mode_str); if (mono_p) cmode = seuss_mode; if (cmode == random_mode) @@ -435,6 +436,16 @@ halo_event (Display *dpy, Window window, void *closure, XEvent *event) static void halo_free (Display *dpy, Window window, void *closure) { + struct state *st = (struct state *) closure; + XFreeGC (dpy, st->draw_gc); + XFreeGC (dpy, st->erase_gc); + XFreeGC (dpy, st->copy_gc); + XFreeGC (dpy, st->merge_gc); + if (st->pixmap) XFreePixmap (dpy, st->pixmap); + if (st->buffer) XFreePixmap (dpy, st->buffer); + free (st->circles); + free (st->colors); + free (st); } XSCREENSAVER_MODULE ("Halo", halo) |