Fix bug #7080 - Quota only shown when logged as root.
[ira/wip.git] / source3 / smbd / fake_file.c
index 6898793d29ee966193cbcde7d024619a31b825d0..9917481351a6b1849af438402fa441dd49fbc6d0 100644 (file)
@@ -126,7 +126,7 @@ NTSTATUS open_fake_file(struct smb_request *req, connection_struct *conn,
        NTSTATUS status;
 
        /* access check */
-       if (conn->server_info->utok.uid != 0) {
+       if (geteuid() == sec_initial_uid()) {
                DEBUG(3, ("open_fake_file_shared: access_denied to "
                          "service[%s] file[%s] user[%s]\n",
                          lp_servicename(SNUM(conn)),