Fix include paths to new location of libutil.
[bbaumbach/samba-autobuild/.git] / source4 / ntvfs / posix / pvfs_search.c
index f33acb80b1f0a926ddbc54fa969386393848026e..b84684573189be632b946af9abfb483e59e846dd 100644 (file)
@@ -7,7 +7,7 @@
 
    This program is free software; you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
-   the Free Software Foundation; either version 2 of the License, or
+   the Free Software Foundation; either version 3 of the License, or
    (at your option) any later version.
    
    This program is distributed in the hope that it will be useful,
@@ -16,8 +16,7 @@
    GNU General Public License for more details.
    
    You should have received a copy of the GNU General Public License
-   along with this program; if not, write to the Free Software
-   Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */
 
 #include "includes.h"
@@ -26,7 +25,7 @@
 #include "librpc/gen_ndr/security.h"
 #include "smbd/service_stream.h"
 #include "lib/events/events.h"
-#include "lib/util/dlinklist.h"
+#include "../lib/util/dlinklist.h"
 
 /* place a reasonable limit on old-style searches as clients tend to
    not send search close requests */
@@ -85,7 +84,7 @@ static NTSTATUS fill_search_info(struct pvfs_state *pvfs,
                                                      in pvfs_list_seek_ofs() for 
                                                      how we cope with this */
 
-       status = pvfs_resolve_partial(pvfs, file, unix_path, fname, &name);
+       status = pvfs_resolve_partial(pvfs, file, unix_path, fname, 0, &name);
        if (!NT_STATUS_IS_OK(status)) {
                return status;
        }
@@ -238,7 +237,7 @@ static NTSTATUS pvfs_search_fill(struct pvfs_state *pvfs, TALLOC_CTX *mem_ctx,
                                 enum smb_search_data_level level,
                                 uint_t *reply_count,
                                 void *search_private, 
-                                BOOL (*callback)(void *, const union smb_search_data *))
+                                bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_dir *dir = search->dir;
        NTSTATUS status;
@@ -314,7 +313,7 @@ static void pvfs_search_cleanup(struct pvfs_state *pvfs)
 static NTSTATUS pvfs_search_first_old(struct ntvfs_module_context *ntvfs,
                                      struct ntvfs_request *req, union smb_search_first *io, 
                                      void *search_private, 
-                                     BOOL (*callback)(void *, const union smb_search_data *))
+                                     bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_dir *dir;
        struct pvfs_state *pvfs = ntvfs->private_data;
@@ -404,7 +403,7 @@ static NTSTATUS pvfs_search_first_old(struct ntvfs_module_context *ntvfs,
 static NTSTATUS pvfs_search_next_old(struct ntvfs_module_context *ntvfs,
                                     struct ntvfs_request *req, union smb_search_next *io, 
                                     void *search_private, 
-                                    BOOL (*callback)(void *, const union smb_search_data *))
+                                    bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_state *pvfs = ntvfs->private_data;
        struct pvfs_search_state *search;
@@ -453,7 +452,7 @@ static NTSTATUS pvfs_search_next_old(struct ntvfs_module_context *ntvfs,
 static NTSTATUS pvfs_search_first_trans2(struct ntvfs_module_context *ntvfs,
                                         struct ntvfs_request *req, union smb_search_first *io, 
                                         void *search_private, 
-                                        BOOL (*callback)(void *, const union smb_search_data *))
+                                        bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_dir *dir;
        struct pvfs_state *pvfs = ntvfs->private_data;
@@ -549,7 +548,7 @@ static NTSTATUS pvfs_search_first_trans2(struct ntvfs_module_context *ntvfs,
 static NTSTATUS pvfs_search_next_trans2(struct ntvfs_module_context *ntvfs,
                                        struct ntvfs_request *req, union smb_search_next *io, 
                                        void *search_private, 
-                                       BOOL (*callback)(void *, const union smb_search_data *))
+                                       bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_state *pvfs = ntvfs->private_data;
        struct pvfs_search_state *search;
@@ -610,7 +609,7 @@ static NTSTATUS pvfs_search_next_trans2(struct ntvfs_module_context *ntvfs,
 static NTSTATUS pvfs_search_first_smb2(struct ntvfs_module_context *ntvfs,
                                       struct ntvfs_request *req, const struct smb2_find *io, 
                                       void *search_private, 
-                                      BOOL (*callback)(void *, const union smb_search_data *))
+                                      bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_dir *dir;
        struct pvfs_state *pvfs = ntvfs->private_data;
@@ -713,7 +712,7 @@ static NTSTATUS pvfs_search_first_smb2(struct ntvfs_module_context *ntvfs,
 static NTSTATUS pvfs_search_next_smb2(struct ntvfs_module_context *ntvfs,
                                      struct ntvfs_request *req, const struct smb2_find *io, 
                                      void *search_private, 
-                                     BOOL (*callback)(void *, const union smb_search_data *))
+                                     bool (*callback)(void *, const union smb_search_data *))
 {
        struct pvfs_state *pvfs = ntvfs->private_data;
        struct pvfs_search_state *search;
@@ -766,7 +765,7 @@ static NTSTATUS pvfs_search_next_smb2(struct ntvfs_module_context *ntvfs,
 NTSTATUS pvfs_search_first(struct ntvfs_module_context *ntvfs,
                           struct ntvfs_request *req, union smb_search_first *io, 
                           void *search_private, 
-                          BOOL (*callback)(void *, const union smb_search_data *))
+                          bool (*callback)(void *, const union smb_search_data *))
 {
        switch (io->generic.level) {
        case RAW_SEARCH_SEARCH:
@@ -788,7 +787,7 @@ NTSTATUS pvfs_search_first(struct ntvfs_module_context *ntvfs,
 NTSTATUS pvfs_search_next(struct ntvfs_module_context *ntvfs,
                          struct ntvfs_request *req, union smb_search_next *io, 
                          void *search_private, 
-                         BOOL (*callback)(void *, const union smb_search_data *))
+                         bool (*callback)(void *, const union smb_search_data *))
 {
        switch (io->generic.level) {
        case RAW_SEARCH_SEARCH: