ypldap.c (302408) | ypldap.c (309872) |
---|---|
1/* $OpenBSD: ypldap.c,v 1.16 2015/11/02 10:06:06 jmatthew Exp $ */ 2/* $FreeBSD */ 3 4/* 5 * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org> 6 * 7 * Permission to use, copy, modify, and distribute this software for any 8 * purpose with or without fee is hereby granted, provided that the above --- 595 unchanged lines hidden (view full) --- 604 if (setgroups(1, &pw->pw_gid) || 605 setresgid(pw->pw_gid, pw->pw_gid, pw->pw_gid) || 606 setresuid(pw->pw_uid, pw->pw_uid, pw->pw_uid)) 607 fatal("cannot drop privileges"); 608#else 609#warning disabling privilege revocation in debug mode 610#endif 611 | 1/* $OpenBSD: ypldap.c,v 1.16 2015/11/02 10:06:06 jmatthew Exp $ */ 2/* $FreeBSD */ 3 4/* 5 * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@openbsd.org> 6 * 7 * Permission to use, copy, modify, and distribute this software for any 8 * purpose with or without fee is hereby granted, provided that the above --- 595 unchanged lines hidden (view full) --- 604 if (setgroups(1, &pw->pw_gid) || 605 setresgid(pw->pw_gid, pw->pw_gid, pw->pw_gid) || 606 setresuid(pw->pw_uid, pw->pw_uid, pw->pw_uid)) 607 fatal("cannot drop privileges"); 608#else 609#warning disabling privilege revocation in debug mode 610#endif 611 |
612 bzero(&tv, sizeof(tv)); | 612 memset(&tv, 0, sizeof(tv)); |
613 evtimer_set(&ev_timer, main_init_timer, &env); 614 evtimer_add(&ev_timer, &tv); 615 616 yp_enable_events(); 617 event_dispatch(); 618 main_shutdown(); 619 620 return (0); --- 30 unchanged lines hidden --- | 613 evtimer_set(&ev_timer, main_init_timer, &env); 614 evtimer_add(&ev_timer, &tv); 615 616 yp_enable_events(); 617 event_dispatch(); 618 main_shutdown(); 619 620 return (0); --- 30 unchanged lines hidden --- |