--- rxvt-unicode/src/main.C 2007/11/15 11:36:15 1.258 +++ rxvt-unicode/src/main.C 2007/11/24 11:06:13 1.264 @@ -183,19 +183,19 @@ pointer_ev (this, &rxvt_term::pointer_cb), #endif #ifdef USE_XIM - im_ev (this, &rxvt_term::im_cb), + im_ev (this, &rxvt_term::im_cb), #endif #ifndef NO_BELL - bell_ev (this, &rxvt_term::bell_cb), + bell_ev (this, &rxvt_term::bell_cb), #endif termwin_ev (this, &rxvt_term::x_cb), - vt_ev (this, &rxvt_term::x_cb), - child_ev (this, &rxvt_term::child_cb), + vt_ev (this, &rxvt_term::x_cb), + child_ev (this, &rxvt_term::child_cb), prepare_ev (this, &rxvt_term::prepare_cb), - flush_ev (this, &rxvt_term::flush_cb), + flush_ev (this, &rxvt_term::flush_cb), destroy_ev (this, &rxvt_term::destroy_cb), - pty_ev (this, &rxvt_term::pty_cb), - incr_ev (this, &rxvt_term::incr_cb) + pty_ev (this, &rxvt_term::pty_cb), + incr_ev (this, &rxvt_term::incr_cb) { cmdbuf_ptr = cmdbuf_endp = cmdbuf_base; @@ -286,6 +286,9 @@ delete [] pix_colors_unfocused; #endif +#ifdef HAVE_BG_PIXMAP + bgPixmap.destroy (); +#endif displays.put (display); scr_release (); @@ -308,6 +311,9 @@ #ifdef KEYSYM_RESOURCE delete keyboard; #endif +#ifndef NO_RESOURCES + XrmDestroyDatabase (option_db); +#endif } // child has exited, usually destroys @@ -372,7 +378,7 @@ } void -rxvt_term::destroy_cb (ev::check &w, int revents) +rxvt_term::destroy_cb (ev::idle &w, int revents) { make_current (); @@ -618,7 +624,7 @@ { ptytty::init (); - if (!ev::ev_default_loop (0)) + if (!ev_default_loop (0)) rxvt_fatal ("cannot initialise libev (bad value for LIBEV_METHODS?)\n"); rxvt_environ = environ; @@ -626,8 +632,8 @@ signal (SIGHUP, SIG_IGN); signal (SIGPIPE, SIG_IGN); - sig_handlers.sw_term.start (SIGTERM); ev::ev_unref (); - sig_handlers.sw_int.start (SIGINT); ev::ev_unref (); + sig_handlers.sw_term.start (SIGTERM); ev_unref (); + sig_handlers.sw_int.start (SIGINT); ev_unref (); /* need to trap SIGURG for SVR4 (Unixware) rlogin */ /* signal (SIGURG, SIG_DFL); */ @@ -1740,6 +1746,14 @@ } #ifdef HAVE_BG_PIXMAP +# if TRACE_PIXMAPS +# undef update_background +int rxvt_term::trace_update_background (const char* file, int line) +{ + fprintf (stderr, "%s:%d:update_background()\n", file, line); + update_background (); +} +# endif int rxvt_term::update_background () {