src/server/plugins/postgresql/vfs.h

branch
webdav
changeset 346
784b24381bed
parent 345
5832e10fc59a
child 366
47bc686fafe4
--- a/src/server/plugins/postgresql/vfs.h	Sun May 08 18:55:36 2022 +0200
+++ b/src/server/plugins/postgresql/vfs.h	Sun May 08 19:29:27 2022 +0200
@@ -39,27 +39,29 @@
 extern "C" {
 #endif
 
+#define PG_ETAG_MAXLEN 48
+    
 typedef struct PgVFS {
     ResourceData *pg_resource;
     PGconn *connection;
 } PgVFS;
 
 typedef struct PgFile {
-    int64_t resource_id;
-    int64_t parent_id;
-    WSBool  iscollection;
-    Oid     oid;
-    int     fd;
-    int     oflags;
-    
-    struct stat s;
+    int64_t      resource_id;
+    int64_t      parent_id;
+    WSBool       iscollection;
+    Oid          oid;
+    int          fd;
+    int          oflags;
+    char         etag[PG_ETAG_MAXLEN];
+    struct stat  s;
 } PgFile;
 
 typedef struct PgDir {
-    VFSFile *file;
-    PGresult *result;
-    int row;
-    int nrows;
+    VFSFile      *file;
+    PGresult     *result;
+    int          row;
+    int          nrows;
 } PgDir;
 
 VFS* pg_vfs_create(Session *sn, Request *rq, pblock *pb);
@@ -83,6 +85,7 @@
         const char **resource_name,
         WSBool *iscollection,
         struct stat *s,
+        char *etag,
         int *res_errno);
 
 void pg_set_stat(

mercurial