diff options
author | Jeremy Allison <jra@samba.org> | 2008-01-09 17:11:04 -0800 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2008-01-09 17:11:04 -0800 |
commit | 253fbf1a6ece5c8dc9759e3535b7f9fa46883c1b (patch) | |
tree | 3e4abe3bc537565b45699fbffaf1a8c0fcbc7f99 /source3/smbd/service.c | |
parent | 9003e8e50fd308bb66bfbd635193e725b2442cbb (diff) | |
download | samba-253fbf1a6ece5c8dc9759e3535b7f9fa46883c1b.tar.gz samba-253fbf1a6ece5c8dc9759e3535b7f9fa46883c1b.tar.xz samba-253fbf1a6ece5c8dc9759e3535b7f9fa46883c1b.zip |
Make use of talloc_pool in the main codepaths. Remove the sub-contexts.
Jeremy.
(This used to be commit bc932b8ad4396f76b71c43efe9a6346f89c3632c)
Diffstat (limited to 'source3/smbd/service.c')
-rw-r--r-- | source3/smbd/service.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/source3/smbd/service.c b/source3/smbd/service.c index 65fc8181446..2588a66b8b9 100644 --- a/source3/smbd/service.c +++ b/source3/smbd/service.c @@ -357,7 +357,6 @@ void load_registry_shares(void) int find_service(fstring service) { int iService; - TALLOC_CTX *frame = talloc_stackframe(); all_string_sub(service,"\\","/",0); @@ -463,8 +462,6 @@ int find_service(fstring service) if (iService < 0) DEBUG(3,("find_service() failed to find service %s\n", service)); - TALLOC_FREE(frame); - return (iService); } @@ -1150,20 +1147,17 @@ static connection_struct *make_connection_snum(int snum, user_struct *vuser, #if SOFTLINK_OPTIMISATION /* resolve any soft links early if possible */ if (vfs_ChDir(conn,conn->connectpath) == 0) { - TALLOC_CTX *ctx = talloc_stackframe(); + TALLOC_CTX *ctx = talloc_tos(); char *s = vfs_GetWd(ctx,s); if (!s) { *status = map_nt_error_from_unix(errno); - TALLOC_FREE(ctx); goto err_root_exit; } if (!set_conn_connectpath(conn,s)) { *status = NT_STATUS_NO_MEMORY; - TALLOC_FREE(ctx); goto err_root_exit; } vfs_ChDir(conn,conn->connectpath); - TALLOC_FREE(ctx); } #endif |