s3-auth inline make_auth_session_info into only caller
authorAndrew Bartlett <abartlet@samba.org>
Tue, 19 Jul 2011 05:58:20 +0000 (15:58 +1000)
committerAndrew Bartlett <abartlet@samba.org>
Tue, 19 Jul 2011 23:17:15 +0000 (09:17 +1000)
source3/auth/auth_util.c
source3/auth/proto.h
source3/auth/server_info.c

index b0deb2c8ab19a4066298e49a4b0ca248dcdfa883..c77406546412a8fa4ed9ba21b293837c9f2a16d0 100644 (file)
@@ -472,7 +472,7 @@ NTSTATUS create_local_token(TALLOC_CTX *mem_ctx,
                return NT_STATUS_LOGON_FAILURE;
        }
 
-       session_info = make_auth_session_info(mem_ctx);
+       session_info = talloc_zero(mem_ctx, struct auth_session_info);
        if (!session_info) {
                return NT_STATUS_NO_MEMORY;
        }
index 4c69a32c1151dd5df557699e991fb24ad6784c02..d51a3e6444dc6d1f36201471d5b540a77ad1bae8 100644 (file)
@@ -225,7 +225,6 @@ struct netr_SamInfo3;
 struct netr_SamInfo6;
 
 struct auth_serversupplied_info *make_server_info(TALLOC_CTX *mem_ctx);
-struct auth_session_info *make_auth_session_info(TALLOC_CTX *mem_ctx);
 NTSTATUS serverinfo_to_SamInfo2(struct auth_serversupplied_info *server_info,
                                uint8_t *pipe_session_key,
                                size_t pipe_session_key_len,
index c78b3f67df9aad505c36581a8501d7265d23b8ba..a53e556d283d2b11fca194e8972c7a4dc4f6ee33 100644 (file)
@@ -63,29 +63,6 @@ struct auth_serversupplied_info *make_server_info(TALLOC_CTX *mem_ctx)
        return result;
 }
 
-/***************************************************************************
- Make a server_info struct. Free with TALLOC_FREE().
-***************************************************************************/
-
-struct auth_session_info *make_auth_session_info(TALLOC_CTX *mem_ctx)
-{
-       struct auth_session_info *result;
-
-       result = talloc_zero(mem_ctx, struct auth_session_info);
-       if (result == NULL) {
-               DEBUG(0, ("talloc failed\n"));
-               return NULL;
-       }
-
-       /* Initialise the unix_token to NULL which may save us from
-          giving away root access if there is a bug in allocating
-          these fields. */
-
-       result->unix_token = NULL;
-
-       return result;
-}
-
 /****************************************************************************
  inits a netr_SamInfo2 structure from an auth_serversupplied_info. sam2 must
  already be initialized and is used as the talloc parent for its members.