mirror of
https://github.com/samba-team/samba.git
synced 2025-11-12 04:23:49 +03:00
r10656: BIG merge from trunk. Features not copied over
* \PIPE\unixinfo
* winbindd's {group,alias}membership new functions
* winbindd's lookupsids() functionality
* swat (trunk changes to be reverted as per discussion with Deryck)
(This used to be commit 939c3cb5d7)
This commit is contained in:
committed by
Gerald (Jerry) Carter
parent
4a2cc231d2
commit
54abd2aa66
@@ -31,7 +31,7 @@ static int show_session(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf,
|
||||
|
||||
memcpy(&sessionid, dbuf.dptr, sizeof(sessionid));
|
||||
|
||||
if (!process_exists(sessionid.pid)) {
|
||||
if (!process_exists_by_pid(sessionid.pid)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -101,8 +101,8 @@ static int show_share(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf,
|
||||
return 0;
|
||||
}
|
||||
|
||||
d_printf("%-10.10s %5d %-12s %s",
|
||||
crec.name,(int)crec.pid,
|
||||
d_printf("%-10.10s %s %-12s %s",
|
||||
crec.name,procid_str_static(&crec.pid),
|
||||
crec.machine,
|
||||
asctime(LocalTime(&crec.start)));
|
||||
|
||||
@@ -125,7 +125,7 @@ static int collect_pid(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf,
|
||||
|
||||
memcpy(&sessionid, dbuf.dptr, sizeof(sessionid));
|
||||
|
||||
if (!process_exists(sessionid.pid))
|
||||
if (!process_exists_by_pid(sessionid.pid))
|
||||
return 0;
|
||||
|
||||
ids->num_entries += 1;
|
||||
@@ -156,14 +156,15 @@ static int show_share_parseable(TDB_CONTEXT *tdb, TDB_DATA kbuf, TDB_DATA dbuf,
|
||||
}
|
||||
|
||||
for (i=0; i<ids->num_entries; i++) {
|
||||
if (ids->entries[i].pid == crec.pid) {
|
||||
struct process_id id = pid_to_procid(ids->entries[i].pid);
|
||||
if (procid_equal(&id, &crec.pid)) {
|
||||
guest = False;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
d_printf("%s\\%d\\%s\\%s\\%s\\%s\\%s",
|
||||
crec.name,(int)crec.pid,
|
||||
d_printf("%s\\%s\\%s\\%s\\%s\\%s\\%s",
|
||||
crec.name,procid_str_static(&crec.pid),
|
||||
guest ? "" : uidtoname(ids->entries[i].uid),
|
||||
guest ? "" : gidtoname(ids->entries[i].gid),
|
||||
crec.machine,
|
||||
|
||||
Reference in New Issue
Block a user