I'm using the following call to get the list of trustees of a
file/directory *and* the owner of that file/directory, whereby the srchPath
specifies the exact path (no search pattern) of the file/directory:
NWScanNSDirectoryForTrustees(conn, NW_NS_LONG, dirHandle, srchPath,
&iterHandle, NULL, NULL, &OwnerID, TI)
But it seems the Owner is only returned when the file/directory also has
trustees. If there are no trustees, the function returns 0x899C
(NO_MORE_TRUSTEES) and the OwnerID remains 0.
Am I missing something or should I use another function for this?
Tx, vha
I've not used this function, but I suspect this is the way it works i.e. no
trustees results in no owner returned. If you get 0 for the ownerID, call
NWGetNSEntryInfo.
John
Tx, vha
While that would simplify coding a little, you aren't losing anything in
terms of efficiency by making the call yourself.
NWScanNSDirectoryForTrustees has to make 2 separate requests to the server,
one for the trustees (more than 1 if more than 20 trustees), then a request
for the ownership and other directory details, there is no NCP function to
get trustees and other information in a single request.
John