Apply some const
[samba.git] / source / nsswitch / winbindd_cache.c
index 91834e476fc7a522f5b631a5a2538a932646e7e1..73918d74f7db99ef61f1a40a8ebb122dbaeb10a8 100644 (file)
@@ -339,10 +339,12 @@ static void refresh_sequence_number(struct winbindd_domain *domain, BOOL force)
 
        get_cache( domain );
 
+#if 0  /* JERRY -- disable as the default cache time is now 5 minutes */
        /* trying to reconnect is expensive, don't do it too often */
        if (domain->sequence_number == DOM_SEQUENCE_NONE) {
                cache_time *= 8;
        }
+#endif
 
        time_diff = t - domain->last_seq_check;
 
@@ -1039,7 +1041,7 @@ do_query:
 /* Lookup user information from a rid */
 static NTSTATUS query_user(struct winbindd_domain *domain, 
                           TALLOC_CTX *mem_ctx, 
-                          DOM_SID *user_sid, 
+                          const DOM_SID *user_sid, 
                           WINBIND_USERINFO *info)
 {
        struct winbind_cache *cache = get_cache(domain);
@@ -1102,7 +1104,7 @@ do_query:
 /* Lookup groups a user is a member of. */
 static NTSTATUS lookup_usergroups(struct winbindd_domain *domain,
                                  TALLOC_CTX *mem_ctx,
-                                 DOM_SID *user_sid, 
+                                 const DOM_SID *user_sid, 
                                  uint32 *num_groups, DOM_SID ***user_gids)
 {
        struct winbind_cache *cache = get_cache(domain);
@@ -1185,7 +1187,7 @@ skip_save:
 
 static NTSTATUS lookup_groupmem(struct winbindd_domain *domain,
                                TALLOC_CTX *mem_ctx,
-                               DOM_SID *group_sid, uint32 *num_names, 
+                               const DOM_SID *group_sid, uint32 *num_names, 
                                DOM_SID ***sid_mem, char ***names, 
                                uint32 **name_types)
 {