ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/src/proxy.C
(Generate patch)

Comparing rxvt-unicode/src/proxy.C (file contents):
Revision 1.1 by root, Wed Jan 25 10:51:26 2006 UTC vs.
Revision 1.3 by root, Wed Jan 25 22:09:33 2006 UTC

303 || gid != getegid ()) 303 || gid != getegid ())
304 { 304 {
305#if PTYTTY_HELPER 305#if PTYTTY_HELPER
306 use_helper (); 306 use_helper ();
307#else 307#else
308 ptytty_warn ("running setuid/setgid without pty helper compiled in, continuing unprivileged.\n"); 308 ptytty_warn ("running setuid/setgid without pty helper compiled in, continuing unprivileged.\n", 0);
309#endif 309#endif
310 310
311 drop_privileges (); 311 drop_privileges ();
312 } 312 }
313} 313}
326 setregid (gid, gid); 326 setregid (gid, gid);
327 setreuid (uid, uid); 327 setreuid (uid, uid);
328#elif HAVE_SETUID 328#elif HAVE_SETUID
329 setgid (gid); 329 setgid (gid);
330 setuid (uid); 330 setuid (uid);
331#else
332# error no way to drop privileges, configure failed?
331#endif 333#endif
332 334
333 if (uid != geteuid () 335 if (uid != geteuid ()
334 || gid != getegid ()) 336 || gid != getegid ())
335 ptytty_fatal ("unable to drop privileges, aborting.\n"); 337 ptytty_fatal ("unable to drop privileges, aborting.\n");

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines