Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

NWScanNSDirectoryForTrustees doesn't always return the owner

5 views
Skip to first unread message

v...@abc.com

unread,
Jun 20, 2006, 11:10:07 AM6/20/06
to
Hi,

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

John Baird

unread,
Jun 21, 2006, 12:35:56 AM6/21/06
to

<v...@abc.com> wrote in message
news:jdUlg.5313$tN4....@prv-forum2.provo.novell.com...

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


v...@abc.com

unread,
Jun 21, 2006, 1:41:56 AM6/21/06
to
That's indeed what I'm currently doing. I was just hoping I could have
retrieved trustee & owner info in 1 call.

Tx, vha

John Baird

unread,
Jun 21, 2006, 6:35:20 PM6/21/06
to

<v...@abc.com> wrote in message
news:E_4mg.5960$tN4....@prv-forum2.provo.novell.com...

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


0 new messages