]> arthur.barton.de Git - netatalk.git/blobdiff - etc/afpd/filedir.c
Merge sf/master
[netatalk.git] / etc / afpd / filedir.c
index 5f6e0f643e5987f101a2068123772eb8a50a21f8..7166c125d36c8af3cae56270fec3924a8e31037e 100644 (file)
@@ -40,6 +40,7 @@ char *strchr (), *strrchr ();
 #include <atalk/bstrlib.h>
 #include <atalk/bstradd.h>
 #include <atalk/acl.h>
+#include <atalk/globals.h>
 #include <atalk/fce_api.h>
 
 #include "directory.h"
@@ -48,7 +49,6 @@ char *strchr (), *strrchr ();
 #include "volume.h"
 #include "fork.h"
 #include "file.h"
-#include "globals.h"
 #include "filedir.h"
 #include "unix.h"
 
@@ -628,14 +628,14 @@ int afp_delete(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf _U_, size
                                fce_register_delete_file( s_path );
 
             struct dir *cachedfile;
-            if ((cachedfile = dircache_search_by_name(vol, dir, upath, strlen(upath), s_path->st.st_ctime))) {
+            if ((cachedfile = dircache_search_by_name(vol, dir, upath, strlen(upath)))) {
                 dircache_remove(vol, cachedfile, DIRCACHE | DIDNAME_INDEX | QUEUE_INDEX);
                 dir_free(cachedfile);
             }
         }
     }
     if ( rc == AFP_OK ) {
-        curdir->offcnt--;
+        curdir->d_offcnt--;
         setvoltime(obj, vol );
     }
 
@@ -776,8 +776,8 @@ int afp_moveandrename(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf _U
             rc = AFPERR_PARAM;
             goto exit;
         }
-        curdir->offcnt++;
-        sdir->offcnt--;
+        curdir->d_offcnt++;
+        sdir->d_offcnt--;
 #ifdef DROPKLUDGE
         if (vol->v_flags & AFPVOL_DROPBOX) {
             /* FIXME did is not always the source id */