--- source/libsmb/libsmbclient.c.orig 2005-11-17 06:09:09.073665787 +0100 +++ source/libsmb/libsmbclient.c 2005-11-17 05:56:50.079229544 +0100 @@ -764,7 +764,7 @@ /* now add it to the cache (internal or external) */ /* Let the cache function set errno if it wants to */ errno = 0; - if (context->callbacks.add_cached_srv_fn(context, srv, server, share, workgroup, username_used)) { + if (context->callbacks.add_cached_srv_fn(context, srv, server, share, workgroup, username)) { int saved_errno = errno; DEBUG(3, (" Failed to add server to cache\n")); errno = saved_errno;