"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/rxvtd.C" between
rxvt-unicode-9.26.tar.bz2 and rxvt-unicode-9.29.tar.bz2

About: rxvt-unicode is a clone of the terminal emulator rxvt.

rxvtd.C  (rxvt-unicode-9.26.tar.bz2):rxvtd.C  (rxvt-unicode-9.29.tar.bz2)
skipping to change at line 46 skipping to change at line 46
#if defined(ENABLE_FRILLS) && defined(_POSIX_MEMLOCK) && _POSIX_MEMLOCK > 0 #if defined(ENABLE_FRILLS) && defined(_POSIX_MEMLOCK) && _POSIX_MEMLOCK > 0
# define ENABLE_MLOCK 1 # define ENABLE_MLOCK 1
#endif #endif
#if ENABLE_MLOCK #if ENABLE_MLOCK
# include <sys/mman.h> # include <sys/mman.h>
#endif #endif
#include <errno.h> #include <errno.h>
#include <libptytty.h>
#include "rxvt.h" #include "rxvt.h"
#include "rxvtdaemon.h" #include "rxvtdaemon.h"
#include "libptytty.h"
struct server : rxvt_connection { struct server : rxvt_connection
{
log_callback log_cb; log_callback log_cb;
getfd_callback getfd_cb; getfd_callback getfd_cb;
void read_cb (ev::io &w, int revents); ev::io read_ev; void read_cb (ev::io &w, int revents); ev::io read_ev;
void log_msg (const char *msg); void log_msg (const char *msg);
int getfd (int remote_fd); int getfd (int remote_fd);
server (int fd) server (int fd)
{ {
read_ev.set <server, &server::read_cb> (this); read_ev.set <server, &server::read_cb> (this);
skipping to change at line 73 skipping to change at line 75
this->fd = fd; this->fd = fd;
fcntl (fd, F_SETFD, FD_CLOEXEC); fcntl (fd, F_SETFD, FD_CLOEXEC);
fcntl (fd, F_SETFL, 0); fcntl (fd, F_SETFL, 0);
read_ev.start (fd, ev::READ); read_ev.start (fd, ev::READ);
} }
void err (const char *format = 0, ...); void err (const char *format = 0, ...);
}; };
struct unix_listener { struct unix_listener
{
int fd; int fd;
void accept_cb (ev::io &w, int revents); ev::io accept_ev; void accept_cb (ev::io &w, int revents); ev::io accept_ev;
unix_listener (int fd); unix_listener (int fd);
static int open (const char *sockname); static int open (const char *sockname);
}; };
unix_listener::unix_listener (int fd) : fd (fd) unix_listener::unix_listener (int fd) : fd (fd)
{ {
skipping to change at line 208 skipping to change at line 211
term->log_hook = &log_cb; term->log_hook = &log_cb;
term->getfd_hook = &getfd_cb; term->getfd_hook = &getfd_cb;
bool success = true; bool success = true;
try try
{ {
term->init (argv, envv); term->init (argv, envv);
} }
catch (const class rxvt_failure_exception &e) catch (const std::exception &e)
{ {
log_msg (e.what());
success = false; success = false;
} }
term->log_hook = 0; term->log_hook = 0;
chdir ("/"); // init might change to different working directory chdir ("/"); // init might change to different working directory
if (!success) if (!success)
term->destroy (); term->destroy ();
skipping to change at line 277 skipping to change at line 281
unsetenv ("LISTEN_FDS"); unsetenv ("LISTEN_FDS");
unsetenv ("LISTEN_FDNAMES"); unsetenv ("LISTEN_FDNAMES");
return n; return n;
} }
#endif #endif
int int
main (int argc, char *argv[]) main (int argc, char *argv[])
{ {
ptytty::init (); try
{
ptytty::init ();
}
catch (const std::exception &e)
{
fputs (e.what (), stderr);
return EXIT_FAILURE;
}
static char opt_fork, opt_opendisplay, opt_quiet; static char opt_fork, opt_opendisplay, opt_quiet;
#if ENABLE_PERL #if ENABLE_PERL
static char *opt_eval; static char *opt_eval;
#endif #endif
#if ENABLE_MLOCK #if ENABLE_MLOCK
static char opt_lock; static char opt_lock;
#endif #endif
for (int i = 1; i < argc; i++) for (int i = 1; i < argc; i++)
 End of changes. 7 change blocks. 
5 lines changed or deleted 17 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)