--- rxvt-unicode/src/main.C 2007/11/19 15:33:34 1.261 +++ rxvt-unicode/src/main.C 2007/11/27 17:45:46 1.267 @@ -286,7 +286,9 @@ delete [] pix_colors_unfocused; #endif +#ifdef HAVE_BG_PIXMAP bgPixmap.destroy (); +#endif displays.put (display); scr_release (); @@ -309,6 +311,9 @@ #ifdef KEYSYM_RESOURCE delete keyboard; #endif +#ifndef NO_RESOURCES + XrmDestroyDatabase (option_db); +#endif } // child has exited, usually destroys @@ -619,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; @@ -627,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); */ @@ -976,14 +981,15 @@ i = atoi (color); if (i >= 8 && i <= 15) - { /* bright colors */ - i -= 8; - pix_colors_focused[idx] = pix_colors_focused[minBrightCOLOR + i]; + { + /* bright colors */ + pix_colors_focused[idx] = pix_colors_focused[minBrightCOLOR + i - 8]; goto done; } if (i >= 0 && i <= 7) - { /* normal colors */ + { + /* normal colors */ pix_colors_focused[idx] = pix_colors_focused[minCOLOR + i]; goto done; } @@ -998,8 +1004,6 @@ pix_colors_focused[idx] = xcol; - /* XSetWindowAttributes attr; */ - /* Cursor cursor; */ done: /*TODO: handle Color_BD, scrollbar background, etc. */ @@ -1743,12 +1747,13 @@ #ifdef HAVE_BG_PIXMAP # if TRACE_PIXMAPS # undef update_background -int rxvt_term::trace_update_background (const char* file, int line) +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 () {