{
int success = 0, tries = 0;
- while (success == 0 && tries < 1) {
+ while (success == 0 && tries < 2) {
if (tries++)
sleep(5*60);
com_err(whoami, 0, "Executing command: %s", cmd);
char *user;
{
if (atoi(av[5])) {
- sleep(1); /* give the ptserver room */
edit_group(1, av[0], "USER", user);
}
}
if (astate == bstate) {
/* Only a modify has to be done */
- code = pr_ChangeEntry(before[U_NAME], after[U_NAME],
- (auid==buid) ? 0 : auid, "");
+ code = pr_ChangeEntry(before[U_NAME], after[U_NAME], auid, "");
if (code) {
critical_alert("incremental",
"Couldn't change user %s (id %d) to %s (id %d): %s",
"Couldn't create user %s (id %d): %s",
after[U_NAME], auid, error_message(code));
}
+ sleep(1); /* give ptserver some time */
+
if (beforec) {
/* Reactivating a user; get his group list */
gethostname(hostname, sizeof(hostname));
after[U_NAME], error_message(code));
return;
}
- av[0] = "RUSER";
+ av[0] = "ruser";
av[1] = after[U_NAME];
code = mr_query("get_lists_of_member", 2, av,
add_user_lists, after[U_NAME]);
}
}
+ sleep(1); /* give ptserver some time */
+
/* We need to make sure the group is properly populated */
if (beforec < L_ACTIVE || atoi(before[L_ACTIVE]) == 0) return;
int code=0;
if (strcmp(av[0], "LIST")) {
- sleep(1); /* give the ptserver room */
edit_group(1, group, av[0], av[1]);
} else {
code = mr_query("get_end_members_of_list", 1, &av[1],
strcpy(buf, "system:");
strcat(buf, group);
+ sleep(1); /* give ptserver some time */
code = (*fn)(member, buf);
if (code) {
if (op==0 && code == PRNOENT) return;