Lines 471-476
Link Here
|
471 |
char *passfile_hold; |
471 |
char *passfile_hold; |
472 |
char passfile_buf[MAXPATHLEN + 2]; |
472 |
char passfile_buf[MAXPATHLEN + 2]; |
473 |
char passfile_hold_buf[MAXPATHLEN + 2]; |
473 |
char passfile_hold_buf[MAXPATHLEN + 2]; |
|
|
474 |
char *passdir; |
475 |
char passdir_buf[MAXPATHLEN + 2]; |
474 |
char *domain = yppasswd_domain; |
476 |
char *domain = yppasswd_domain; |
475 |
static struct sockaddr_in clntaddr; |
477 |
static struct sockaddr_in clntaddr; |
476 |
static struct timeval t_saved, t_test; |
478 |
static struct timeval t_saved, t_test; |
Lines 603-612
Link Here
|
603 |
"%s.hold", passfile); |
605 |
"%s.hold", passfile); |
604 |
passfile_hold = (char *)&passfile_hold_buf; |
606 |
passfile_hold = (char *)&passfile_hold_buf; |
605 |
|
607 |
|
|
|
608 |
/* Hold a copy of the passfile in passdir */ |
609 |
snprintf(passdir_buf, sizeof(passdir_buf), "%s", passfile); |
610 |
passdir = (char *)&passdir_buf; |
606 |
|
611 |
|
607 |
/* Step 5: make a new password file with the updated info. */ |
612 |
/* Step 5: make a new password file with the updated info. */ |
608 |
|
613 |
|
609 |
if (pw_init(dirname(passfile), passfile)) { |
614 |
if (pw_init(dirname(passdir), passfile)) { |
610 |
yp_error("pw_init() failed"); |
615 |
yp_error("pw_init() failed"); |
611 |
return &result; |
616 |
return &result; |
612 |
} |
617 |
} |
Lines 729-734
Link Here
|
729 |
char *passfile_hold; |
734 |
char *passfile_hold; |
730 |
char passfile_buf[MAXPATHLEN + 2]; |
735 |
char passfile_buf[MAXPATHLEN + 2]; |
731 |
char passfile_hold_buf[MAXPATHLEN + 2]; |
736 |
char passfile_hold_buf[MAXPATHLEN + 2]; |
|
|
737 |
char *passdir; |
738 |
char passdir_buf[MAXPATHLEN + 2]; |
732 |
struct sockaddr_in *rqhost; |
739 |
struct sockaddr_in *rqhost; |
733 |
SVCXPRT *transp; |
740 |
SVCXPRT *transp; |
734 |
struct passwd newpasswd; |
741 |
struct passwd newpasswd; |
Lines 829-835
Link Here
|
829 |
"%s.hold", passfile); |
836 |
"%s.hold", passfile); |
830 |
passfile_hold = (char *)&passfile_hold_buf; |
837 |
passfile_hold = (char *)&passfile_hold_buf; |
831 |
|
838 |
|
832 |
if (pw_init(dirname(passfile), passfile)) { |
839 |
/* Hold a copy of the passfile in passdir */ |
|
|
840 |
snprintf(passdir_buf, sizeof(passdir_buf), "%s", passfile); |
841 |
passdir = (char *)&passdir_buf; |
842 |
|
843 |
if (pw_init(dirname(passdir), passfile)) { |
833 |
yp_error("pw_init() failed"); |
844 |
yp_error("pw_init() failed"); |
834 |
return &result; |
845 |
return &result; |
835 |
} |
846 |
} |