From: Eric Bollengier Date: Wed, 6 Sep 2023 09:54:11 +0000 (+0200) Subject: Backport aligned_dev.h X-Git-Tag: Beta-15.0.0~110 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b978b75efee7d3472ccd31b622277785dece5a94;p=thirdparty%2Fbacula.git Backport aligned_dev.h --- diff --git a/bacula/src/stored/aligned_dev.h b/bacula/src/stored/aligned_dev.h index 1f016617c..eb09cd9e3 100644 --- a/bacula/src/stored/aligned_dev.h +++ b/bacula/src/stored/aligned_dev.h @@ -24,6 +24,9 @@ #define _ALIGNED_DEV_H_ class aligned_dev : public file_dev { +protected: + void get_volume_fpath(const char *vol_name, POOLMEM **buf); + public: aligned_dev(); @@ -38,6 +41,8 @@ public: void clear_adata_addr(); /* DEVICE virtual functions that we redefine */ + void set_file_size(uint64_t val); + uint64_t update_file_size(uint64_t add); void setVolCatName(const char *name); void setVolCatStatus(const char *status); void free_dcr_blocks(DCR *dcr); @@ -105,6 +110,11 @@ public: bool get_os_device_freespace(); bool is_fs_nearly_full(uint64_t threshold); int rehydrate_record(DCR *dcr, DEV_RECORD *rec); + + int set_writable(int fd, const char *vol_name); + int set_readonly(int fd, const char *vol_name); + int set_atime(int fd, const char *vol_name, btime_t val); + /* * Locking and blocking calls */