getcifsacl: fix up printing of REVISION: and CONTROL: fields
authorJeff Layton <jlayton@samba.org>
Wed, 7 Nov 2012 15:20:46 +0000 (10:20 -0500)
committerJeff Layton <jlayton@samba.org>
Wed, 7 Nov 2012 15:20:46 +0000 (10:20 -0500)
They need endianness conversion too...

Signed-off-by: Jeff Layton <jlayton@samba.org>
getcifsacl.c

index c576fc0b4b3374e6b71c3857dd0654a91b3d43d8..b76c8ece539c46bddd22c96ed6c8f348f6ca037e 100644 (file)
@@ -327,8 +327,8 @@ parse_sec_desc(struct cifs_ntsd *pntsd, ssize_t acl_len, int raw)
                                le32toh(pntsd->gsidoffset));
        dacloffset = le32toh(pntsd->dacloffset);
        dacl_ptr = (struct cifs_ctrl_acl *)((char *)pntsd + dacloffset);
-       printf("REVISION:0x%x\n", pntsd->revision);
-       printf("CONTROL:0x%x\n", pntsd->type);
+       printf("REVISION:0x%x\n", le16toh(pntsd->revision));
+       printf("CONTROL:0x%x\n", le16toh(pntsd->type));
 
        rc = parse_sid(owner_sid_ptr, end_of_acl, "OWNER", raw);
        if (rc)