[PATCH] remove FLAG_SAM_* from sam/

Stefan (metze) Metzmacher metze at metzemix.de
Mon Oct 14 19:17:00 GMT 2002


Hi Jelmer,

can you please apply this patch.

it remove the FLAG_SAM_* macros they are no longer defined in smb.h

so make bin/samtest failed :-(

I'm working on a patch for sam/ that do the same as my last patch to passdb/


metze
-----------------------------------------------------------------------------
Stefan "metze" Metzmacher <metze at metzemix.de>
-------------- next part --------------
diff -Npur --exclude=CVS --exclude=*.bak --exclude=*.o --exclude=*.po --exclude=.#* HEAD/source/sam/account.c HEAD-fix/source/sam/account.c
--- HEAD/source/sam/account.c	Thu Aug 29 14:29:53 2002
+++ HEAD-fix/source/sam/account.c	Mon Oct 14 21:06:47 2002
@@ -37,8 +37,6 @@ static void sam_fill_default_account(SAM
         /* Don't change these timestamp settings without a good reason.
            They are important for NT member server compatibility. */
 
-	account->private.init_flag		    = FLAG_SAM_UNINIT;
-
 	/* FIXME: We should actually call get_nt_time_max() or sthng 
 	 * here */
 	unix_to_nt_time(&(account->private.logoff_time),get_time_t_max());
diff -Npur --exclude=CVS --exclude=*.bak --exclude=*.o --exclude=*.po --exclude=.#* HEAD/source/sam/get_set_account.c HEAD-fix/source/sam/get_set_account.c
--- HEAD/source/sam/get_set_account.c	Sat Sep  7 18:02:01 2002
+++ HEAD-fix/source/sam/get_set_account.c	Mon Oct 14 21:08:27 2002
@@ -355,11 +355,11 @@ NTSTATUS sam_get_account_unknown_3(const
  Collection of set...() functions for SAM_ACCOUNT_HANDLE_INFO.
  ********************************************************************/
 
-NTSTATUS sam_set_account_acct_ctrl(SAM_ACCOUNT_HANDLE *sampass, uint16 flags)
+NTSTATUS sam_set_account_acct_ctrl(SAM_ACCOUNT_HANDLE *sampass, uint16 acct_ctrl)
 {
 	SAM_ASSERT(sampass);
 		
-	sampass->private.acct_ctrl = flags;
+	sampass->private.acct_ctrl = acct_ctrl;
 
 	return NT_STATUS_OK;
 }
@@ -370,8 +370,6 @@ NTSTATUS sam_set_account_logon_time(SAM_
 
 	sampass->private.logon_time = mytime;
 
-	if (store)
-		sam_set_account_init_flag(sampass, FLAG_SAM_LOGONTIME); 
 
 	return NT_STATUS_UNSUCCESSFUL;
 }
@@ -382,9 +380,6 @@ NTSTATUS sam_set_account_logoff_time(SAM
 
 	sampass->private.logoff_time = mytime;
 
-	if (store)
-		sam_set_account_init_flag(sampass, FLAG_SAM_LOGOFFTIME); 
-
 	return NT_STATUS_OK;
 }
 
@@ -394,8 +389,6 @@ NTSTATUS sam_set_account_kickoff_time(SA
 
 	sampass->private.kickoff_time = mytime;
 
-	if (store)
-		sam_set_account_init_flag(sampass, FLAG_SAM_KICKOFFTIME); 
 
 	return NT_STATUS_OK;
 }
@@ -406,8 +399,6 @@ NTSTATUS sam_set_account_pass_can_change
 
 	sampass->private.pass_can_change_time = mytime;
 
-	if (store)
-		sam_set_account_init_flag(sampass, FLAG_SAM_CANCHANGETIME); 
 
 	return NT_STATUS_OK;
 }
@@ -418,9 +409,6 @@ NTSTATUS sam_set_account_pass_must_chang
 
 	sampass->private.pass_must_change_time = mytime;
 
-	if (store)
-		sam_set_account_init_flag(sampass, FLAG_SAM_MUSTCHANGETIME); 
-
 	return NT_STATUS_OK;
 }
 
@@ -585,7 +573,6 @@ NTSTATUS sam_set_account_logon_script(SA
 
 	sampass->private.logon_script = talloc_strdup(sampass->mem_ctx, logon_script);
 	
-	sam_set_account_init_flag(sampass, FLAG_SAM_LOGONSCRIPT);
 
 	return NT_STATUS_OK;
 }
@@ -602,11 +589,6 @@ NTSTATUS sam_set_account_profile_path(SA
  
 	sampass->private.profile_path = talloc_strdup(sampass->mem_ctx, profile_path);
 		
-	if (store) {
-		DEBUG(10, ("sam_set_profile_path: setting profile path sam flag!\n"));
-		sam_set_account_init_flag(sampass, FLAG_SAM_PROFILE);
-	}
-
 	return NT_STATUS_OK;
 }
 
@@ -623,11 +605,6 @@ NTSTATUS sam_set_account_dir_drive(SAM_A
  
 	sampass->private.dir_drive = talloc_strdup(sampass->mem_ctx, dir_drive);
 		
-	if (store) {
-		DEBUG(10, ("sam_set_dir_drive: setting dir drive sam flag!\n"));
-		sam_set_account_init_flag(sampass, FLAG_SAM_DRIVE);
-	}
-
 	return NT_STATUS_OK;
 }
 
@@ -644,11 +621,6 @@ NTSTATUS sam_set_account_homedir(SAM_ACC
  
 	sampass->private.home_dir = talloc_strdup(sampass->mem_ctx, home_dir);
 		
-	if (store) {
-		DEBUG(10, ("sam_set_homedir: setting home dir sam flag!\n"));
-		sam_set_account_init_flag(sampass, FLAG_SAM_SMBHOME);
-	}
-
 	return NT_STATUS_OK;
 }
 
@@ -719,6 +691,7 @@ NTSTATUS sam_set_account_munged_dial(SAM
 	SAM_ASSERT(sampass);
 
 	sampass->private.munged_dial = talloc_strdup(sampass->mem_ctx, munged_dial);
+	
 	return NT_STATUS_OK;
 }
 


More information about the samba-technical mailing list