proposal: libsmbclient functionality addition

Tom Jansen tom at
Wed Jun 19 06:38:45 GMT 2002


> > and make all the functions use current_handle as the handle.
> NO.
> Please NO.  I *really* would like to see this move in the opposite
> direction - with all function taking a context and using it.  It
> *really* isn't that hard to change and it eliminates all sorts of
> bugs.

Alright, I can see your point. I personally don't mind to change the interface.
I'll get working on at it right away if Richard approves too. I assume this will
be samba3.0 stuff so no backporting to the stable branch is necessary (at least
not yet).

The way it will be if I'm understanding you correctly is:

All functions that instantiate a connection (open, opendir, fstat, etc) get the
handle as their first arg. All other functions that work on fd's keep
functioning the same. The fd-table stays global (to simplify the uniqueness of
fd's) as well as the server-connection table (same reason). The
server-connection-cache will become on a per-handle basis so each handle has
their private connections with unique server_fd's.

> If you want to know the kind of code I like, see the passdb subsystem.

That is my kind of "nice" code too.


Tom Jansen -- tom at
Ninja  ISD --

More information about the samba-technical mailing list