getpwent.c (29479) | getpwent.c (29574) |
---|---|
1/* 2 * Copyright (c) 1988, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 410 unchanged lines hidden (view full) --- 419 return(0); 420 } 421 } 422 if (!latch) { 423 setnetgrent(grp+2); 424 latch++; 425 } 426again: | 1/* 2 * Copyright (c) 1988, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 410 unchanged lines hidden (view full) --- 419 return(0); 420 } 421 } 422 if (!latch) { 423 setnetgrent(grp+2); 424 latch++; 425 } 426again: |
427 if (getnetgrent(&host, &user, &domain) == NULL) { | 427 if (getnetgrent(&host, &user, &domain) == 0) { |
428 if ((gr = getgrnam(grp+2)) != NULL) 429 goto grpagain; 430 latch = 0; 431 _pw_stepping_yp = 0; 432 return(0); 433 } else { 434 if (lookup(user)) 435 goto again; --- 7 unchanged lines hidden (view full) --- 443 if (lookup(grp+1)) 444 return(0); 445 return(_getyppass(&_pw_passwd, grp+1, "passwd.byname")); 446 } 447 } else { 448 if (grp[1] == '@') { 449 setnetgrent(grp+2); 450 rv = 0; | 428 if ((gr = getgrnam(grp+2)) != NULL) 429 goto grpagain; 430 latch = 0; 431 _pw_stepping_yp = 0; 432 return(0); 433 } else { 434 if (lookup(user)) 435 goto again; --- 7 unchanged lines hidden (view full) --- 443 if (lookup(grp+1)) 444 return(0); 445 return(_getyppass(&_pw_passwd, grp+1, "passwd.byname")); 446 } 447 } else { 448 if (grp[1] == '@') { 449 setnetgrent(grp+2); 450 rv = 0; |
451 while(getnetgrent(&host, &user, &domain) != NULL) { | 451 while(getnetgrent(&host, &user, &domain) != 0) { |
452 store(user); 453 rv++; 454 } 455 if (!rv && (gr = getgrnam(grp+2)) != NULL) { 456 while(gr->gr_mem) { 457 store(gr->gr_mem); 458 gr->gr_mem++; 459 } --- 376 unchanged lines hidden --- | 452 store(user); 453 rv++; 454 } 455 if (!rv && (gr = getgrnam(grp+2)) != NULL) { 456 while(gr->gr_mem) { 457 store(gr->gr_mem); 458 gr->gr_mem++; 459 } --- 376 unchanged lines hidden --- |