s3-nterr: within nt_errstr() compare codes using NT_STATUS_V().
authorGünther Deschner <gd@samba.org>
Wed, 2 Mar 2011 23:39:44 +0000 (00:39 +0100)
committerGünther Deschner <gd@samba.org>
Fri, 4 Mar 2011 00:18:42 +0000 (01:18 +0100)
This is to avoid future very special NT_STATUS_EQUAL semantics within s4.

Guenther

source3/libsmb/nterr.c

index fdb6fe3c8b4f5e4febca22a75adc37d4b71351df..866c025fbba8cc532efc37692668a1aaccb9a3a5 100644 (file)
@@ -699,7 +699,8 @@ const char *nt_errstr(NTSTATUS nt_code)
        }
 
        while (nt_errs[idx].nt_errstr != NULL) {
        }
 
        while (nt_errs[idx].nt_errstr != NULL) {
-               if (NT_STATUS_EQUAL(nt_errs[idx].nt_errcode, nt_code)) {
+               if (NT_STATUS_V(nt_errs[idx].nt_errcode) ==
+                   NT_STATUS_V(nt_code)) {
                        return nt_errs[idx].nt_errstr;
                }
                idx++;
                        return nt_errs[idx].nt_errstr;
                }
                idx++;