Author: mimir
Date: 2004-08-10 21:23:48 +0000 (Tue, 10 Aug 2004)
New Revision: 1707
WebSVN: http://websvn.samba.org/websvn/changeset.php?rep=samba&path=/&rev=1707&nolog=1
Log:
Meet also the case when passdb backend does not implement trust passwords
handling functions. Many don't, at the moment.


rafal


Modified:
   trunk/source/utils/pdbedit.c

Changeset:
Modified: trunk/source/utils/pdbedit.c
===================================================================
--- trunk/source/utils/pdbedit.c        2004-08-10 21:16:19 UTC (rev 1706)
+++ trunk/source/utils/pdbedit.c        2004-08-10 21:23:48 UTC (rev 1707)
@@ -854,11 +854,15 @@
        nt_status = in->pdb_update_trust_passwd(in, &trust);
 
        talloc_destroy(mem_ctx);
-       if (!NT_STATUS_IS_OK(nt_status)) {
-               printf("Coulnd't modify trust password\n");
+       if (NT_STATUS_IS_OK(nt_status)) {
+               return 0;
+
+       } else if (NT_STATUS_EQUAL(nt_status, NT_STATUS_NOT_IMPLEMENTED)) {
+               printf("Error: this functionality is not supported by your current 
passdb backend!\n");
+               return -1;
        }
 
-       return NT_STATUS_IS_OK(nt_status) ? 0 : -1;
+       return -1;
 }
 
 

Reply via email to