]> arthur.barton.de Git - netatalk.git/blobdiff - etc/afpd/fork.c
Merge master
[netatalk.git] / etc / afpd / fork.c
index 4133eebdbe40544bee0f1d77810f617ee8fb865a..e075945cc5253aa8d796790f029aab97db845aae 100644 (file)
@@ -16,7 +16,6 @@
 #include <sys/socket.h>
 #include <inttypes.h>
 
-#include <netatalk/at.h>
 #include <atalk/dsi.h>
 #include <atalk/afp.h>
 #include <atalk/adouble.h>
 #include <atalk/util.h>
 #include <atalk/cnid.h>
 #include <atalk/bstradd.h>
+#include <atalk/globals.h>
 
 #include "fork.h"
 #include "file.h"
-#include "globals.h"
 #include "directory.h"
 #include "desktop.h"
 #include "volume.h"
@@ -1304,6 +1303,12 @@ static int write_fork(AFPObj *obj, char *ibuf, size_t ibuflen _U_, char *rbuf, s
     if ( ad_meta_fileno( ofork->of_ad ) != -1 ) /* META */
         ofork->of_flags |= AFPFORK_DIRTY;
 
+    /* we have modified any fork, remember until close_fork */
+    ofork->of_flags |= AFPFORK_MODIFIED;
+
+    /* update write count */
+    ofork->of_vol->v_written += reqcount;
+
     *rbuflen = set_off_t (offset, rbuf, is64);
     return( AFP_OK );