From: Christophe Courtaut Date: Fri, 9 Aug 2013 09:58:58 +0000 (+0200) Subject: Fix compilation -Wmismatched-tags warnings X-Git-Tag: v0.68~46^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=e1666d0400ecef464d33480e4290896404b7a7bd;p=ceph.git Fix compilation -Wmismatched-tags warnings Keep consistency in the code to not generate warnings of this type. Signed-off-by: Christophe Courtaut --- diff --git a/src/auth/AuthClientHandler.h b/src/auth/AuthClientHandler.h index 24df969994a8..5d129adc111d 100644 --- a/src/auth/AuthClientHandler.h +++ b/src/auth/AuthClientHandler.h @@ -24,7 +24,7 @@ #include "common/Timer.h" class CephContext; -class MAuthReply; +struct MAuthReply; class AuthClientHandler; class RotatingKeyRing; diff --git a/src/client/Client.h b/src/client/Client.h index 1117ff3b0af4..f66b5096b030 100644 --- a/src/client/Client.h +++ b/src/client/Client.h @@ -59,13 +59,13 @@ class MClientRequest; class MClientSession; class MClientRequest; class MClientRequestForward; -class MClientLease; +struct MClientLease; class MClientCaps; class MClientCapRelease; -class DirStat; -class LeaseStat; -class InodeStat; +struct DirStat; +struct LeaseStat; +struct InodeStat; class Filer; class Objecter; @@ -110,12 +110,12 @@ class Inode; struct Cap; class Dir; class Dentry; -class SnapRealm; -class Fh; -class CapSnap; +struct SnapRealm; +struct Fh; +struct CapSnap; -class MetaSession; -class MetaRequest; +struct MetaSession; +struct MetaRequest; typedef void (*client_ino_callback_t)(void *handle, vinodeno_t ino, int64_t off, int64_t len); @@ -439,7 +439,7 @@ protected: void maybe_update_snaprealm(SnapRealm *realm, snapid_t snap_created, snapid_t snap_highwater, vector& snaps); - void handle_snap(class MClientSnap *m); + void handle_snap(struct MClientSnap *m); void handle_caps(class MClientCaps *m); void handle_cap_import(MetaSession *session, Inode *in, class MClientCaps *m); void handle_cap_export(MetaSession *session, Inode *in, class MClientCaps *m); diff --git a/src/client/Inode.h b/src/client/Inode.h index af4830b5c77d..cc054a654fa3 100644 --- a/src/client/Inode.h +++ b/src/client/Inode.h @@ -13,10 +13,10 @@ #include "osdc/ObjectCacher.h" #include "include/assert.h" -class MetaSession; +struct MetaSession; class Dentry; class Dir; -class SnapRealm; +struct SnapRealm; class Inode; struct Cap { diff --git a/src/client/MetaSession.h b/src/client/MetaSession.h index 01575efb6ba5..a6cf634c9690 100644 --- a/src/client/MetaSession.h +++ b/src/client/MetaSession.h @@ -11,10 +11,10 @@ #include "messages/MClientCapRelease.h" -class Cap; +struct Cap; class Inode; -class CapSnap; -class MetaRequest; +struct CapSnap; +struct MetaRequest; class MClientCapRelease; struct MetaSession { diff --git a/src/common/LogClient.h b/src/common/LogClient.h index 8fa7bd14ce65..d62147e4a993 100644 --- a/src/common/LogClient.h +++ b/src/common/LogClient.h @@ -27,7 +27,7 @@ class MLogAck; class Messenger; class MonMap; class Message; -class Connection; +struct Connection; class LogClientTemp { diff --git a/src/include/assert.h b/src/include/assert.h index fa49a2f3e0f2..38c0eeb44a1e 100644 --- a/src/include/assert.h +++ b/src/include/assert.h @@ -12,12 +12,12 @@ # include "acconfig.h" #endif -struct CephContext; +class CephContext; #ifdef __cplusplus namespace ceph { -class BackTrace; +struct BackTrace; struct FailedAssertion { BackTrace *backtrace; diff --git a/src/include/cephfs/libcephfs.h b/src/include/cephfs/libcephfs.h index 93e86e7c0315..bf3b12ce5aa3 100644 --- a/src/include/cephfs/libcephfs.h +++ b/src/include/cephfs/libcephfs.h @@ -38,9 +38,9 @@ extern "C" { # error libceph: must define __USE_FILE_OFFSET64 or readdir results will be corrupted #endif -struct ceph_mount_info; +class ceph_mount_info; struct ceph_dir_result; -struct CephContext; +class CephContext; /* setattr mask bits */ #ifndef CEPH_SETATTR_MODE @@ -82,7 +82,7 @@ const char *ceph_version(int *major, int *minor, int *patch); * pass in NULL, and the id will be the process id of the client. * @returns 0 on success, negative error code on failure */ -int ceph_create(struct ceph_mount_info **cmount, const char * const id); +int ceph_create(class ceph_mount_info **cmount, const char * const id); /** * Create a mount handle from a CephContext, which holds the configuration @@ -94,7 +94,7 @@ int ceph_create(struct ceph_mount_info **cmount, const char * const id); * @param conf reuse this pre-existing CephContext config * @returns 0 on success, negative error code on failure */ -int ceph_create_with_context(struct ceph_mount_info **cmount, struct CephContext *conf); +int ceph_create_with_context(class ceph_mount_info **cmount, class CephContext *conf); /** * Perform a mount using the path for the root of the mount. @@ -105,7 +105,7 @@ int ceph_create_with_context(struct ceph_mount_info **cmount, struct CephContext * be "/". Passing in NULL is equivalent to "/". * @returns 0 on success, negative error code on failure */ -int ceph_mount(struct ceph_mount_info *cmount, const char *root); +int ceph_mount(class ceph_mount_info *cmount, const char *root); /** * Unmount a mount handle. @@ -113,7 +113,7 @@ int ceph_mount(struct ceph_mount_info *cmount, const char *root); * @param cmount the mount handle * @return 0 on success, negative error code on failure */ -int ceph_unmount(struct ceph_mount_info *cmount); +int ceph_unmount(class ceph_mount_info *cmount); /** * Destroy the mount handle. @@ -124,7 +124,7 @@ int ceph_unmount(struct ceph_mount_info *cmount); * @param cmount the mount handle * @return 0 on success, negative error code on failure. */ -int ceph_release(struct ceph_mount_info *cmount); +int ceph_release(class ceph_mount_info *cmount); /** * Deprecated. Unmount and destroy the ceph mount handle. This should be @@ -134,7 +134,7 @@ int ceph_release(struct ceph_mount_info *cmount); * * @param cmount the mount handle to shutdown */ -void ceph_shutdown(struct ceph_mount_info *cmount); +void ceph_shutdown(class ceph_mount_info *cmount); /** * Extract the CephContext from the mount point handle. @@ -142,14 +142,14 @@ void ceph_shutdown(struct ceph_mount_info *cmount); * @param cmount the ceph mount handle to get the context from. * @returns the CephContext associated with the mount handle. */ -struct CephContext *ceph_get_mount_context(struct ceph_mount_info *cmount); +class CephContext *ceph_get_mount_context(class ceph_mount_info *cmount); /* * Check mount status. * * Return non-zero value if mounted. Otherwise, zero. */ -int ceph_is_mounted(struct ceph_mount_info *cmount); +int ceph_is_mounted(class ceph_mount_info *cmount); /** @} init */ @@ -167,7 +167,7 @@ int ceph_is_mounted(struct ceph_mount_info *cmount); * @param path_list the configuration file path * @returns 0 on success, negative error code on failure */ -int ceph_conf_read_file(struct ceph_mount_info *cmount, const char *path_list); +int ceph_conf_read_file(class ceph_mount_info *cmount, const char *path_list); /** * Parse the command line arguments and load the configuration parameters. @@ -177,7 +177,7 @@ int ceph_conf_read_file(struct ceph_mount_info *cmount, const char *path_list); * @param argv the argument list * @returns 0 on success, negative error code on failure */ -int ceph_conf_parse_argv(struct ceph_mount_info *cmount, int argc, const char **argv); +int ceph_conf_parse_argv(class ceph_mount_info *cmount, int argc, const char **argv); /** * Configure the cluster handle based on an environment variable @@ -194,7 +194,7 @@ int ceph_conf_parse_argv(struct ceph_mount_info *cmount, int argc, const char ** * @param var name of the environment variable to read * @returns 0 on success, negative error code on failure */ -int ceph_conf_parse_env(struct ceph_mount_info *cmount, const char *var); +int ceph_conf_parse_env(class ceph_mount_info *cmount, const char *var); /** Sets a configuration value from a string. * @@ -204,7 +204,7 @@ int ceph_conf_parse_env(struct ceph_mount_info *cmount, const char *var); * * @returns 0 on success, negative error code otherwise. */ -int ceph_conf_set(struct ceph_mount_info *cmount, const char *option, const char *value); +int ceph_conf_set(class ceph_mount_info *cmount, const char *option, const char *value); /** * Gets the configuration value as a string. @@ -215,7 +215,7 @@ int ceph_conf_set(struct ceph_mount_info *cmount, const char *option, const char * @param len the length of the buffer. * @returns the size of the buffer filled in with the value, or negative error code on failure */ -int ceph_conf_get(struct ceph_mount_info *cmount, const char *option, char *buf, size_t len); +int ceph_conf_get(class ceph_mount_info *cmount, const char *option, char *buf, size_t len); /** @} config */ @@ -236,7 +236,7 @@ int ceph_conf_get(struct ceph_mount_info *cmount, const char *option, char *buf, * @param stbuf the file system statistics filled in by this function. * @return 0 on success, negative error code otherwise. */ -int ceph_statfs(struct ceph_mount_info *cmount, const char *path, struct statvfs *stbuf); +int ceph_statfs(class ceph_mount_info *cmount, const char *path, struct statvfs *stbuf); /** * Synchronize all filesystem data to persistent media. @@ -244,7 +244,7 @@ int ceph_statfs(struct ceph_mount_info *cmount, const char *path, struct statvfs * @param cmount the ceph mount handle to use for performing the sync_fs. * @returns 0 on success or negative error code on failure. */ -int ceph_sync_fs(struct ceph_mount_info *cmount); +int ceph_sync_fs(class ceph_mount_info *cmount); /** * Get the current working directory. @@ -252,7 +252,7 @@ int ceph_sync_fs(struct ceph_mount_info *cmount); * @param cmount the ceph mount to get the current working directory for. * @returns the path to the current working directory */ -const char* ceph_getcwd(struct ceph_mount_info *cmount); +const char* ceph_getcwd(class ceph_mount_info *cmount); /** * Change the current working directory. @@ -261,7 +261,7 @@ const char* ceph_getcwd(struct ceph_mount_info *cmount); * @param path the path to the working directory to change into. * @returns 0 on success, negative error code otherwise. */ -int ceph_chdir(struct ceph_mount_info *cmount, const char *s); +int ceph_chdir(class ceph_mount_info *cmount, const char *s); /** @} fsops */ @@ -281,7 +281,7 @@ int ceph_chdir(struct ceph_mount_info *cmount, const char *s); * @param dirpp the directory result pointer structure to fill in. * @returns 0 on success or negative error code otherwise. */ -int ceph_opendir(struct ceph_mount_info *cmount, const char *name, struct ceph_dir_result **dirpp); +int ceph_opendir(class ceph_mount_info *cmount, const char *name, struct ceph_dir_result **dirpp); /** * Close the open directory. @@ -290,7 +290,7 @@ int ceph_opendir(struct ceph_mount_info *cmount, const char *name, struct ceph_d * @param dirp the directory result pointer (set by ceph_opendir) to close * @returns 0 on success or negative error code on failure. */ -int ceph_closedir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp); +int ceph_closedir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp); /** * Get the next entry in an open directory. @@ -302,7 +302,7 @@ int ceph_closedir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp); * is empty. This pointer should not be freed by the caller, and is only safe to * access between return and the next call to ceph_readdir or ceph_closedir. */ -struct dirent * ceph_readdir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp); +struct dirent * ceph_readdir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp); /** * A safe version of ceph_readdir, where the directory entry struct is allocated by the caller. @@ -314,7 +314,7 @@ struct dirent * ceph_readdir(struct ceph_mount_info *cmount, struct ceph_dir_res * @returns 1 if the next entry was filled in, 0 if the end of the directory stream was reached, * and a negative error code on failure. */ -int ceph_readdir_r(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de); +int ceph_readdir_r(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de); /** * A safe version of ceph_readdir that also returns the file statistics (readdir+stat). @@ -328,7 +328,7 @@ int ceph_readdir_r(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, * @returns 1 if the next entry was filled in, 0 if the end of the directory stream was reached, * and a negative error code on failure. */ -int ceph_readdirplus_r(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de, +int ceph_readdirplus_r(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de, struct stat *st, int *stmask); /** @@ -342,7 +342,7 @@ int ceph_readdirplus_r(struct ceph_mount_info *cmount, struct ceph_dir_result *d * @returns the length of the buffer that was filled in, will always be multiples of sizeof(struct dirent), or a * negative error code. If the buffer is not large enough for a single entry, -ERANGE is returned. */ -int ceph_getdents(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, char *name, int buflen); +int ceph_getdents(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, char *name, int buflen); /** * Gets multiple directory names. @@ -355,7 +355,7 @@ int ceph_getdents(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, * @returns the length of the buffer filled in with entry names, or a negative error code on failure. * If the buffer isn't large enough for a single entry, -ERANGE is returned. */ -int ceph_getdnames(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, char *name, int buflen); +int ceph_getdnames(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, char *name, int buflen); /** * Rewind the directory stream to the beginning of the directory. @@ -363,7 +363,7 @@ int ceph_getdnames(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, * @param cmount the ceph mount handle to use for performing the rewinddir. * @param dirp the directory stream pointer to rewind. */ -void ceph_rewinddir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp); +void ceph_rewinddir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp); /** * Get the current position of a directory stream. @@ -374,7 +374,7 @@ void ceph_rewinddir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp * by ceph_telldir do not have a particular order (cannot be compared with * inequality). */ -loff_t ceph_telldir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp); +loff_t ceph_telldir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp); /** * Move the directory stream to a position specified by the given offset. @@ -385,7 +385,7 @@ loff_t ceph_telldir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp * a value returned by seekdir. Note that this value does not refer to the nth * entry in a directory, and can not be manipulated with plus or minus. */ -void ceph_seekdir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, loff_t offset); +void ceph_seekdir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, loff_t offset); /** * Create a directory. @@ -396,7 +396,7 @@ void ceph_seekdir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, * @param mode the permissions the directory should have once created. * @returns 0 on success or a negative return code on error. */ -int ceph_mkdir(struct ceph_mount_info *cmount, const char *path, mode_t mode); +int ceph_mkdir(class ceph_mount_info *cmount, const char *path, mode_t mode); /** * Create multiple directories at once. @@ -407,7 +407,7 @@ int ceph_mkdir(struct ceph_mount_info *cmount, const char *path, mode_t mode); * @param mode the permissions the directory should have once created. * @returns 0 on success or a negative return code on error. */ -int ceph_mkdirs(struct ceph_mount_info *cmount, const char *path, mode_t mode); +int ceph_mkdirs(class ceph_mount_info *cmount, const char *path, mode_t mode); /** * Remove a directory. @@ -416,7 +416,7 @@ int ceph_mkdirs(struct ceph_mount_info *cmount, const char *path, mode_t mode); * @param path the path of the directory to remove. * @returns 0 on success or a negative return code on error. */ -int ceph_rmdir(struct ceph_mount_info *cmount, const char *path); +int ceph_rmdir(class ceph_mount_info *cmount, const char *path); /** @} dir */ @@ -435,7 +435,7 @@ int ceph_rmdir(struct ceph_mount_info *cmount, const char *path); * @param newname the path to the new file/directory to link from. * @returns 0 on success or a negative return code on error. */ -int ceph_link(struct ceph_mount_info *cmount, const char *existing, const char *newname); +int ceph_link(class ceph_mount_info *cmount, const char *existing, const char *newname); /** * Read a symbolic link. @@ -446,7 +446,7 @@ int ceph_link(struct ceph_mount_info *cmount, const char *existing, const char * * @param size the length of the buffer * @returns 0 on success or negative error code on failure */ -int ceph_readlink(struct ceph_mount_info *cmount, const char *path, char *buf, loff_t size); +int ceph_readlink(class ceph_mount_info *cmount, const char *path, char *buf, loff_t size); /** * Creates a symbolic link. @@ -456,7 +456,7 @@ int ceph_readlink(struct ceph_mount_info *cmount, const char *path, char *buf, l * @param newname the path to the new file/directory to link from. * @returns 0 on success or a negative return code on failure. */ -int ceph_symlink(struct ceph_mount_info *cmount, const char *existing, const char *newname); +int ceph_symlink(class ceph_mount_info *cmount, const char *existing, const char *newname); /** @} links */ @@ -475,7 +475,7 @@ int ceph_symlink(struct ceph_mount_info *cmount, const char *existing, const cha * @param path the path of the file or link to unlink. * @returns 0 on success or negative error code on failure. */ -int ceph_unlink(struct ceph_mount_info *cmount, const char *path); +int ceph_unlink(class ceph_mount_info *cmount, const char *path); /** * Rename a file or directory. @@ -485,7 +485,7 @@ int ceph_unlink(struct ceph_mount_info *cmount, const char *path); * @param to the new name of the file or directory * @returns 0 on success or negative error code on failure. */ -int ceph_rename(struct ceph_mount_info *cmount, const char *from, const char *to); +int ceph_rename(class ceph_mount_info *cmount, const char *from, const char *to); /** * Get a file's statistics and attributes. @@ -495,7 +495,7 @@ int ceph_rename(struct ceph_mount_info *cmount, const char *from, const char *to * @param stbuf the stat struct that will be filled in with the file's statistics. * @returns 0 on success or negative error code on failure. */ -int ceph_stat(struct ceph_mount_info *cmount, const char *path, struct stat *stbuf); +int ceph_stat(class ceph_mount_info *cmount, const char *path, struct stat *stbuf); /** * Get a file's statistics and attributes, without following symlinks. @@ -505,7 +505,7 @@ int ceph_stat(struct ceph_mount_info *cmount, const char *path, struct stat *stb * @param stbuf the stat struct that will be filled in with the file's statistics. * @returns 0 on success or negative error code on failure. */ -int ceph_lstat(struct ceph_mount_info *cmount, const char *path, struct stat *stbuf); +int ceph_lstat(class ceph_mount_info *cmount, const char *path, struct stat *stbuf); /** * Set a file's attributes. @@ -516,7 +516,7 @@ int ceph_lstat(struct ceph_mount_info *cmount, const char *path, struct stat *st * @param mask a mask of all the stat values that have been set on the stat struct. * @returns 0 on success or negative error code on failure. */ -int ceph_setattr(struct ceph_mount_info *cmount, const char *relpath, struct stat *attr, int mask); +int ceph_setattr(class ceph_mount_info *cmount, const char *relpath, struct stat *attr, int mask); /** * Change the mode bits (permissions) of a file/directory. @@ -526,7 +526,7 @@ int ceph_setattr(struct ceph_mount_info *cmount, const char *relpath, struct sta * @param mode the new permissions to set. * @returns 0 on success or a negative error code on failure. */ -int ceph_chmod(struct ceph_mount_info *cmount, const char *path, mode_t mode); +int ceph_chmod(class ceph_mount_info *cmount, const char *path, mode_t mode); /** * Change the mode bits (permissions) of an open file. @@ -536,7 +536,7 @@ int ceph_chmod(struct ceph_mount_info *cmount, const char *path, mode_t mode); * @param mode the new permissions to set. * @returns 0 on success or a negative error code on failure. */ -int ceph_fchmod(struct ceph_mount_info *cmount, int fd, mode_t mode); +int ceph_fchmod(class ceph_mount_info *cmount, int fd, mode_t mode); /** * Change the ownership of a file/directory. @@ -547,7 +547,7 @@ int ceph_fchmod(struct ceph_mount_info *cmount, int fd, mode_t mode); * @param gid the group id to set on the file/directory. * @returns 0 on success or negative error code on failure. */ -int ceph_chown(struct ceph_mount_info *cmount, const char *path, int uid, int gid); +int ceph_chown(class ceph_mount_info *cmount, const char *path, int uid, int gid); /** * Change the ownership of a file from an open file descriptor. @@ -558,7 +558,7 @@ int ceph_chown(struct ceph_mount_info *cmount, const char *path, int uid, int gi * @param gid the group id to set on the file/directory. * @returns 0 on success or negative error code on failure. */ -int ceph_fchown(struct ceph_mount_info *cmount, int fd, int uid, int gid); +int ceph_fchown(class ceph_mount_info *cmount, int fd, int uid, int gid); /** * Change the ownership of a file/directory, don't follow symlinks. @@ -569,7 +569,7 @@ int ceph_fchown(struct ceph_mount_info *cmount, int fd, int uid, int gid); * @param gid the group id to set on the file/directory. * @returns 0 on success or negative error code on failure. */ -int ceph_lchown(struct ceph_mount_info *cmount, const char *path, int uid, int gid); +int ceph_lchown(class ceph_mount_info *cmount, const char *path, int uid, int gid); /** * Change file/directory last access and modification times. @@ -579,7 +579,7 @@ int ceph_lchown(struct ceph_mount_info *cmount, const char *path, int uid, int g * @param buf holding the access and modification times to set on the file. * @returns 0 on success or negative error code on failure. */ -int ceph_utime(struct ceph_mount_info *cmount, const char *path, struct utimbuf *buf); +int ceph_utime(class ceph_mount_info *cmount, const char *path, struct utimbuf *buf); /** * Truncate the file to the given size. If this operation causes the @@ -590,7 +590,7 @@ int ceph_utime(struct ceph_mount_info *cmount, const char *path, struct utimbuf * @param size the new size of the file. * @returns 0 on success or a negative error code on failure. */ -int ceph_truncate(struct ceph_mount_info *cmount, const char *path, loff_t size); +int ceph_truncate(class ceph_mount_info *cmount, const char *path, loff_t size); /** * Make a block or character special file. @@ -604,7 +604,7 @@ int ceph_truncate(struct ceph_mount_info *cmount, const char *path, loff_t size) * it is ignored. * @returns 0 on success or negative error code on failure. */ -int ceph_mknod(struct ceph_mount_info *cmount, const char *path, mode_t mode, dev_t rdev); +int ceph_mknod(class ceph_mount_info *cmount, const char *path, mode_t mode, dev_t rdev); /** * Create and/or open a file. * @@ -616,7 +616,7 @@ int ceph_mknod(struct ceph_mount_info *cmount, const char *path, mode_t mode, de * is specified in the flags. * @returns a non-negative file descriptor number on success or a negative error code on failure. */ -int ceph_open(struct ceph_mount_info *cmount, const char *path, int flags, mode_t mode); +int ceph_open(class ceph_mount_info *cmount, const char *path, int flags, mode_t mode); /** * Create and/or open a file with a specific file layout. @@ -633,7 +633,7 @@ int ceph_open(struct ceph_mount_info *cmount, const char *path, int flags, mode_ * @param data_pool name of target data pool name (optional, NULL or empty string for default) * @returns a non-negative file descriptor number on success or a negative error code on failure. */ -int ceph_open_layout(struct ceph_mount_info *cmount, const char *path, int flags, +int ceph_open_layout(class ceph_mount_info *cmount, const char *path, int flags, mode_t mode, int stripe_unit, int stripe_count, int object_size, const char *data_pool); @@ -644,7 +644,7 @@ int ceph_open_layout(struct ceph_mount_info *cmount, const char *path, int flags * @param fd the file descriptor referring to the open file. * @returns 0 on success or a negative error code on failure. */ -int ceph_close(struct ceph_mount_info *cmount, int fd); +int ceph_close(class ceph_mount_info *cmount, int fd); /** * Reposition the open file stream based on the given offset. @@ -659,7 +659,7 @@ int ceph_close(struct ceph_mount_info *cmount, int fd); * SEEK_END: the offset is set to the end of the file plus @ref offset bytes. * @returns 0 on success or a negative error code on failure. */ -loff_t ceph_lseek(struct ceph_mount_info *cmount, int fd, loff_t offset, int whence); +loff_t ceph_lseek(class ceph_mount_info *cmount, int fd, loff_t offset, int whence); /** * Read data from the file. * @@ -671,7 +671,7 @@ loff_t ceph_lseek(struct ceph_mount_info *cmount, int fd, loff_t offset, int whe * function reads from the current offset of the file descriptor. * @returns the number of bytes read into buf, or a negative error code on failure. */ -int ceph_read(struct ceph_mount_info *cmount, int fd, char *buf, loff_t size, loff_t offset); +int ceph_read(class ceph_mount_info *cmount, int fd, char *buf, loff_t size, loff_t offset); /** * Write data to a file. @@ -684,7 +684,7 @@ int ceph_read(struct ceph_mount_info *cmount, int fd, char *buf, loff_t size, lo * function writes to the current offset of the file descriptor. * @returns the number of bytes written, or a negative error code */ -int ceph_write(struct ceph_mount_info *cmount, int fd, const char *buf, loff_t size, +int ceph_write(class ceph_mount_info *cmount, int fd, const char *buf, loff_t size, loff_t offset); /** @@ -695,7 +695,7 @@ int ceph_write(struct ceph_mount_info *cmount, int fd, const char *buf, loff_t s * @param size the new size of the file * @returns 0 on success or a negative error code on failure. */ -int ceph_ftruncate(struct ceph_mount_info *cmount, int fd, loff_t size); +int ceph_ftruncate(class ceph_mount_info *cmount, int fd, loff_t size); /** * Synchronize an open file to persistent media. @@ -706,7 +706,7 @@ int ceph_ftruncate(struct ceph_mount_info *cmount, int fd, loff_t size); * or just data (1). * @return 0 on success or a negative error code on failure. */ -int ceph_fsync(struct ceph_mount_info *cmount, int fd, int syncdataonly); +int ceph_fsync(class ceph_mount_info *cmount, int fd, int syncdataonly); /** * Get the open file's statistics. @@ -717,7 +717,7 @@ int ceph_fsync(struct ceph_mount_info *cmount, int fd, int syncdataonly); * function. * @returns 0 on success or a negative error code on failure */ -int ceph_fstat(struct ceph_mount_info *cmount, int fd, struct stat *stbuf); +int ceph_fstat(class ceph_mount_info *cmount, int fd, struct stat *stbuf); /** @} file */ @@ -738,7 +738,7 @@ int ceph_fstat(struct ceph_mount_info *cmount, int fd, struct stat *stbuf); * @param size the size of the pre-allocated buffer * @returns the size of the value or a negative error code on failure. */ -int ceph_getxattr(struct ceph_mount_info *cmount, const char *path, const char *name, +int ceph_getxattr(class ceph_mount_info *cmount, const char *path, const char *name, void *value, size_t size); /** @@ -754,7 +754,7 @@ int ceph_getxattr(struct ceph_mount_info *cmount, const char *path, const char * * @param size the size of the pre-allocated buffer * @returns the size of the value or a negative error code on failure. */ -int ceph_lgetxattr(struct ceph_mount_info *cmount, const char *path, const char *name, +int ceph_lgetxattr(class ceph_mount_info *cmount, const char *path, const char *name, void *value, size_t size); /** @@ -766,7 +766,7 @@ int ceph_lgetxattr(struct ceph_mount_info *cmount, const char *path, const char * @param size the size of the list buffer. * @returns the size of the resulting list filled in. */ -int ceph_listxattr(struct ceph_mount_info *cmount, const char *path, char *list, size_t size); +int ceph_listxattr(class ceph_mount_info *cmount, const char *path, char *list, size_t size); /** * Get the list of extended attribute keys on a file, but do not follow symbolic links. @@ -777,7 +777,7 @@ int ceph_listxattr(struct ceph_mount_info *cmount, const char *path, char *list, * @param size the size of the list buffer. * @returns the size of the resulting list filled in. */ -int ceph_llistxattr(struct ceph_mount_info *cmount, const char *path, char *list, size_t size); +int ceph_llistxattr(class ceph_mount_info *cmount, const char *path, char *list, size_t size); /** * Remove an extended attribute from a file. @@ -787,7 +787,7 @@ int ceph_llistxattr(struct ceph_mount_info *cmount, const char *path, char *list * @param name the name of the extended attribute to remove. * @returns 0 on success or a negative error code on failure. */ -int ceph_removexattr(struct ceph_mount_info *cmount, const char *path, const char *name); +int ceph_removexattr(class ceph_mount_info *cmount, const char *path, const char *name); /** * Remove the extended attribute from a file, do not follow symbolic links. @@ -797,7 +797,7 @@ int ceph_removexattr(struct ceph_mount_info *cmount, const char *path, const cha * @param name the name of the extended attribute to remove. * @returns 0 on success or a negative error code on failure. */ -int ceph_lremovexattr(struct ceph_mount_info *cmount, const char *path, const char *name); +int ceph_lremovexattr(class ceph_mount_info *cmount, const char *path, const char *name); /** * Set an extended attribute on a file. @@ -812,7 +812,7 @@ int ceph_lremovexattr(struct ceph_mount_info *cmount, const char *path, const ch * CEPH_XATTR_REPLACE: replace the extended attribute, Must already exist. * @returns 0 on success or a negative error code on failure. */ -int ceph_setxattr(struct ceph_mount_info *cmount, const char *path, const char *name, +int ceph_setxattr(class ceph_mount_info *cmount, const char *path, const char *name, const void *value, size_t size, int flags); /** @@ -828,7 +828,7 @@ int ceph_setxattr(struct ceph_mount_info *cmount, const char *path, const char * * CEPH_XATTR_REPLACE: replace the extended attribute, Must already exist. * @returns 0 on success or a negative error code on failure. */ -int ceph_lsetxattr(struct ceph_mount_info *cmount, const char *path, const char *name, +int ceph_lsetxattr(class ceph_mount_info *cmount, const char *path, const char *name, const void *value, size_t size, int flags); /** @} xattr */ @@ -847,7 +847,7 @@ int ceph_lsetxattr(struct ceph_mount_info *cmount, const char *path, const char * @param fh the open file descriptor referring to the file to get the striping unit of. * @returns the striping unit of the file or a negative error code on failure. */ -int ceph_get_file_stripe_unit(struct ceph_mount_info *cmount, int fh); +int ceph_get_file_stripe_unit(class ceph_mount_info *cmount, int fh); /** * Get the file striping unit. @@ -856,7 +856,7 @@ int ceph_get_file_stripe_unit(struct ceph_mount_info *cmount, int fh); * @param path the path of the file/directory get the striping unit of. * @returns the striping unit of the file or a negative error code on failure. */ -int ceph_get_path_stripe_unit(struct ceph_mount_info *cmount, const char *path); +int ceph_get_path_stripe_unit(class ceph_mount_info *cmount, const char *path); /** * Get the file striping count from an open file descriptor. @@ -865,7 +865,7 @@ int ceph_get_path_stripe_unit(struct ceph_mount_info *cmount, const char *path); * @param fh the open file descriptor referring to the file to get the striping count of. * @returns the striping count of the file or a negative error code on failure. */ -int ceph_get_file_stripe_count(struct ceph_mount_info *cmount, int fh); +int ceph_get_file_stripe_count(class ceph_mount_info *cmount, int fh); /** * Get the file striping count. @@ -874,7 +874,7 @@ int ceph_get_file_stripe_count(struct ceph_mount_info *cmount, int fh); * @param path the path of the file/directory get the striping count of. * @returns the striping count of the file or a negative error code on failure. */ -int ceph_get_path_stripe_count(struct ceph_mount_info *cmount, const char *path); +int ceph_get_path_stripe_count(class ceph_mount_info *cmount, const char *path); /** * Get the file object size from an open file descriptor. @@ -883,7 +883,7 @@ int ceph_get_path_stripe_count(struct ceph_mount_info *cmount, const char *path) * @param fh the open file descriptor referring to the file to get the object size of. * @returns the object size of the file or a negative error code on failure. */ -int ceph_get_file_object_size(struct ceph_mount_info *cmount, int fh); +int ceph_get_file_object_size(class ceph_mount_info *cmount, int fh); /** * Get the file object size. @@ -892,7 +892,7 @@ int ceph_get_file_object_size(struct ceph_mount_info *cmount, int fh); * @param path the path of the file/directory get the object size of. * @returns the object size of the file or a negative error code on failure. */ -int ceph_get_path_object_size(struct ceph_mount_info *cmount, const char *path); +int ceph_get_path_object_size(class ceph_mount_info *cmount, const char *path); /** * Get the file pool information from an open file descriptor. @@ -901,7 +901,7 @@ int ceph_get_path_object_size(struct ceph_mount_info *cmount, const char *path); * @param fh the open file descriptor referring to the file to get the pool information of. * @returns the ceph pool id that the file is in */ -int ceph_get_file_pool(struct ceph_mount_info *cmount, int fh); +int ceph_get_file_pool(class ceph_mount_info *cmount, int fh); /** * Get the file pool information. @@ -910,7 +910,7 @@ int ceph_get_file_pool(struct ceph_mount_info *cmount, int fh); * @param path the path of the file/directory get the pool information of. * @returns the ceph pool id that the file is in */ -int ceph_get_path_pool(struct ceph_mount_info *cmount, const char *path); +int ceph_get_path_pool(class ceph_mount_info *cmount, const char *path); /** * Get the name of the pool a opened file is stored in, @@ -924,7 +924,7 @@ int ceph_get_path_pool(struct ceph_mount_info *cmount, const char *path); * @param buflen size of the buffer * @returns length in bytes of the pool name, or -ERANGE if the buffer is not large enough. */ -int ceph_get_file_pool_name(struct ceph_mount_info *cmount, int fh, char *buf, size_t buflen); +int ceph_get_file_pool_name(class ceph_mount_info *cmount, int fh, char *buf, size_t buflen); /** * get the name of a pool by id @@ -937,7 +937,7 @@ int ceph_get_file_pool_name(struct ceph_mount_info *cmount, int fh, char *buf, s * @param buflen size of the buffer * @returns length in bytes of the pool name, or -ERANGE if the buffer is not large enough */ -int ceph_get_pool_name(struct ceph_mount_info *cmount, int pool, char *buf, size_t buflen); +int ceph_get_pool_name(class ceph_mount_info *cmount, int pool, char *buf, size_t buflen); /** * Get the name of the pool a file is stored in @@ -951,7 +951,7 @@ int ceph_get_pool_name(struct ceph_mount_info *cmount, int pool, char *buf, size * @param buflen size of the buffer * @returns length in bytes of the pool name, or -ERANGE if the buffer is not large enough. */ -int ceph_get_path_pool_name(struct ceph_mount_info *cmount, const char *path, char *buf, size_t buflen); +int ceph_get_path_pool_name(class ceph_mount_info *cmount, const char *path, char *buf, size_t buflen); /** * Get the file layout from an open file descriptor. @@ -964,7 +964,7 @@ int ceph_get_path_pool_name(struct ceph_mount_info *cmount, const char *path, ch * @param pg_pool where to store the ceph pool id that the file is in * @returns 0 on success or a negative error code on failure. */ -int ceph_get_file_layout(struct ceph_mount_info *cmount, int fh, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool); +int ceph_get_file_layout(class ceph_mount_info *cmount, int fh, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool); /** * Get the file layout. @@ -977,7 +977,7 @@ int ceph_get_file_layout(struct ceph_mount_info *cmount, int fh, int *stripe_uni * @param pg_pool where to store the ceph pool id that the file is in * @returns 0 on success or a negative error code on failure. */ -int ceph_get_path_layout(struct ceph_mount_info *cmount, const char *path, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool); +int ceph_get_path_layout(class ceph_mount_info *cmount, const char *path, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool); /** * Get the file replication information from an open file descriptor. @@ -986,7 +986,7 @@ int ceph_get_path_layout(struct ceph_mount_info *cmount, const char *path, int * * @param fh the open file descriptor referring to the file to get the replication information of. * @returns the replication factor of the file. */ -int ceph_get_file_replication(struct ceph_mount_info *cmount, int fh); +int ceph_get_file_replication(class ceph_mount_info *cmount, int fh); /** * Get the file replication information. @@ -995,7 +995,7 @@ int ceph_get_file_replication(struct ceph_mount_info *cmount, int fh); * @param path the path of the file/directory get the replication information of. * @returns the replication factor of the file. */ -int ceph_get_path_replication(struct ceph_mount_info *cmount, const char *path); +int ceph_get_path_replication(class ceph_mount_info *cmount, const char *path); /** * Get the id of the named pool. @@ -1004,7 +1004,7 @@ int ceph_get_path_replication(struct ceph_mount_info *cmount, const char *path); * @param pool_name the name of the pool. * @returns the pool id, or a negative error code on failure. */ -int ceph_get_pool_id(struct ceph_mount_info *cmount, const char *pool_name); +int ceph_get_pool_id(class ceph_mount_info *cmount, const char *pool_name); /** * Get the pool replication factor. @@ -1013,7 +1013,7 @@ int ceph_get_pool_id(struct ceph_mount_info *cmount, const char *pool_name); * @param pool_id the pool id to look up * @returns the replication factor, or a negative error code on failure. */ -int ceph_get_pool_replication(struct ceph_mount_info *cmount, int pool_id); +int ceph_get_pool_replication(class ceph_mount_info *cmount, int pool_id); /** * Get the OSD address where the primary copy of a file stripe is located. @@ -1027,7 +1027,7 @@ int ceph_get_pool_replication(struct ceph_mount_info *cmount, int pool_id); * @returns the size of the addressed filled into the @ref addr parameter, or a negative * error code on failure. */ -int ceph_get_file_stripe_address(struct ceph_mount_info *cmount, int fd, loff_t offset, +int ceph_get_file_stripe_address(class ceph_mount_info *cmount, int fd, loff_t offset, struct sockaddr_storage *addr, int naddr); /** @@ -1043,7 +1043,7 @@ int ceph_get_file_stripe_address(struct ceph_mount_info *cmount, int fd, loff_t * @returns the number of items stored in the output array, or -ERANGE if the * array is not large enough. */ -int ceph_get_file_extent_osds(struct ceph_mount_info *cmount, int fh, +int ceph_get_file_extent_osds(class ceph_mount_info *cmount, int fh, loff_t offset, loff_t *length, int *osds, int nosds); /** @@ -1060,7 +1060,7 @@ int ceph_get_file_extent_osds(struct ceph_mount_info *cmount, int fh, * @returns the amount of bytes written into the buffer, or -ERANGE if the * array is not large enough. */ -int ceph_get_osd_crush_location(struct ceph_mount_info *cmount, +int ceph_get_osd_crush_location(class ceph_mount_info *cmount, int osd, char *path, size_t len); /** @@ -1071,7 +1071,7 @@ int ceph_get_osd_crush_location(struct ceph_mount_info *cmount, * @param addr the OSD network address. * @returns zero on success, other returns a negative error code. */ -int ceph_get_osd_addr(struct ceph_mount_info *cmount, int osd, +int ceph_get_osd_addr(class ceph_mount_info *cmount, int osd, struct sockaddr_storage *addr); /** @@ -1079,7 +1079,7 @@ int ceph_get_osd_addr(struct ceph_mount_info *cmount, int osd, * @param cmount the ceph mount handle. * @returns the stripe unit granularity or a negative error code on failure. */ -int ceph_get_stripe_unit_granularity(struct ceph_mount_info *cmount); +int ceph_get_stripe_unit_granularity(class ceph_mount_info *cmount); /** @} filelayout */ @@ -1087,11 +1087,11 @@ int ceph_get_stripe_unit_granularity(struct ceph_mount_info *cmount); * No longer available. Do not use. * These functions will return -EOPNOTSUPP. */ -int ceph_set_default_file_stripe_unit(struct ceph_mount_info *cmount, int stripe); -int ceph_set_default_file_stripe_count(struct ceph_mount_info *cmount, int count); -int ceph_set_default_object_size(struct ceph_mount_info *cmount, int size); -int ceph_set_default_preferred_pg(struct ceph_mount_info *cmount, int osd); -int ceph_set_default_file_replication(struct ceph_mount_info *cmount, int replication); +int ceph_set_default_file_stripe_unit(class ceph_mount_info *cmount, int stripe); +int ceph_set_default_file_stripe_count(class ceph_mount_info *cmount, int count); +int ceph_set_default_object_size(class ceph_mount_info *cmount, int size); +int ceph_set_default_preferred_pg(class ceph_mount_info *cmount, int osd); +int ceph_set_default_file_replication(class ceph_mount_info *cmount, int replication); /** * Read from local replicas when possible. @@ -1101,7 +1101,7 @@ int ceph_set_default_file_replication(struct ceph_mount_info *cmount, int replic * for reads. * @returns 0 */ -int ceph_localize_reads(struct ceph_mount_info *cmount, int val); +int ceph_localize_reads(class ceph_mount_info *cmount, int val); /** * Get the osd id of the local osd (if any) @@ -1110,7 +1110,7 @@ int ceph_localize_reads(struct ceph_mount_info *cmount, int val); * @returns the osd (if any) local to the node where this call is made, otherwise * -1 is returned. */ -int ceph_get_local_osd(struct ceph_mount_info *cmount); +int ceph_get_local_osd(class ceph_mount_info *cmount); /** @} default_filelayout */ @@ -1122,7 +1122,7 @@ int ceph_get_local_osd(struct ceph_mount_info *cmount); * @returns the current capabilities issued to this client * for the open file */ -int ceph_debug_get_fd_caps(struct ceph_mount_info *cmount, int fd); +int ceph_debug_get_fd_caps(class ceph_mount_info *cmount, int fd); /** * Get the capabilities currently issued to the client. @@ -1132,7 +1132,7 @@ int ceph_debug_get_fd_caps(struct ceph_mount_info *cmount, int fd); * @returns the current capabilities issued to this client * for the file */ -int ceph_debug_get_file_caps(struct ceph_mount_info *cmount, const char *path); +int ceph_debug_get_file_caps(class ceph_mount_info *cmount, const char *path); #ifdef __cplusplus } diff --git a/src/include/rados/librados.hpp b/src/include/rados/librados.hpp index f9c51ab6926d..cf193b36d727 100644 --- a/src/include/rados/librados.hpp +++ b/src/include/rados/librados.hpp @@ -18,12 +18,12 @@ namespace librados { using ceph::bufferlist; - class AioCompletionImpl; + struct AioCompletionImpl; class IoCtx; - class IoCtxImpl; + struct IoCtxImpl; class ObjectOperationImpl; - class ObjListCtx; - class PoolAsyncCompletionImpl; + struct ObjListCtx; + struct PoolAsyncCompletionImpl; class RadosClient; typedef void *list_ctx_t; diff --git a/src/libcephfs.cc b/src/libcephfs.cc index 16b130a435a5..d257dbabec69 100644 --- a/src/libcephfs.cc +++ b/src/libcephfs.cc @@ -240,7 +240,7 @@ extern "C" const char *ceph_version(int *pmajor, int *pminor, int *ppatch) return VERSION; } -extern "C" int ceph_create_with_context(struct ceph_mount_info **cmount, CephContext *cct) +extern "C" int ceph_create_with_context(class ceph_mount_info **cmount, CephContext *cct) { uint64_t nonce = 0; @@ -249,11 +249,11 @@ extern "C" int ceph_create_with_context(struct ceph_mount_info **cmount, CephCon nonce &= ~0xffff; nonce |= (uint64_t)getpid(); - *cmount = new struct ceph_mount_info(nonce, cct); + *cmount = new class ceph_mount_info(nonce, cct); return 0; } -extern "C" int ceph_create(struct ceph_mount_info **cmount, const char * const id) +extern "C" int ceph_create(class ceph_mount_info **cmount, const char * const id) { CephInitParameters iparams(CEPH_ENTITY_TYPE_CLIENT); if (id) { @@ -266,12 +266,12 @@ extern "C" int ceph_create(struct ceph_mount_info **cmount, const char * const i return ceph_create_with_context(cmount, cct); } -extern "C" int ceph_unmount(struct ceph_mount_info *cmount) +extern "C" int ceph_unmount(class ceph_mount_info *cmount) { return cmount->unmount(); } -extern "C" int ceph_release(struct ceph_mount_info *cmount) +extern "C" int ceph_release(class ceph_mount_info *cmount) { if (cmount->is_mounted()) return -EISCONN; @@ -279,35 +279,35 @@ extern "C" int ceph_release(struct ceph_mount_info *cmount) return 0; } -extern "C" void ceph_shutdown(struct ceph_mount_info *cmount) +extern "C" void ceph_shutdown(class ceph_mount_info *cmount) { cmount->shutdown(); delete cmount; } -extern "C" int ceph_conf_read_file(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_conf_read_file(class ceph_mount_info *cmount, const char *path) { return cmount->conf_read_file(path); } -extern "C" int ceph_conf_parse_argv(struct ceph_mount_info *cmount, int argc, +extern "C" int ceph_conf_parse_argv(class ceph_mount_info *cmount, int argc, const char **argv) { return cmount->conf_parse_argv(argc, argv); } -extern "C" int ceph_conf_parse_env(struct ceph_mount_info *cmount, const char *name) +extern "C" int ceph_conf_parse_env(class ceph_mount_info *cmount, const char *name) { return cmount->conf_parse_env(name); } -extern "C" int ceph_conf_set(struct ceph_mount_info *cmount, const char *option, +extern "C" int ceph_conf_set(class ceph_mount_info *cmount, const char *option, const char *value) { return cmount->conf_set(option, value); } -extern "C" int ceph_conf_get(struct ceph_mount_info *cmount, const char *option, +extern "C" int ceph_conf_get(class ceph_mount_info *cmount, const char *option, char *buf, size_t len) { if (buf == NULL) { @@ -316,7 +316,7 @@ extern "C" int ceph_conf_get(struct ceph_mount_info *cmount, const char *option, return cmount->conf_get(option, buf, len); } -extern "C" int ceph_mount(struct ceph_mount_info *cmount, const char *root) +extern "C" int ceph_mount(class ceph_mount_info *cmount, const char *root) { std::string mount_root; if (root) @@ -324,12 +324,12 @@ extern "C" int ceph_mount(struct ceph_mount_info *cmount, const char *root) return cmount->mount(mount_root); } -extern "C" int ceph_is_mounted(struct ceph_mount_info *cmount) +extern "C" int ceph_is_mounted(class ceph_mount_info *cmount) { return cmount->is_mounted() ? 1 : 0; } -extern "C" int ceph_statfs(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_statfs(class ceph_mount_info *cmount, const char *path, struct statvfs *stbuf) { if (!cmount->is_mounted()) @@ -337,26 +337,26 @@ extern "C" int ceph_statfs(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->statfs(path, stbuf); } -extern "C" int ceph_get_local_osd(struct ceph_mount_info *cmount) +extern "C" int ceph_get_local_osd(class ceph_mount_info *cmount) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->get_local_osd(); } -extern "C" const char* ceph_getcwd(struct ceph_mount_info *cmount) +extern "C" const char* ceph_getcwd(class ceph_mount_info *cmount) { return cmount->get_cwd(); } -extern "C" int ceph_chdir (struct ceph_mount_info *cmount, const char *s) +extern "C" int ceph_chdir (class ceph_mount_info *cmount, const char *s) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->chdir(s); } -extern "C" int ceph_opendir(struct ceph_mount_info *cmount, +extern "C" int ceph_opendir(class ceph_mount_info *cmount, const char *name, struct ceph_dir_result **dirpp) { if (!cmount->is_mounted()) @@ -364,14 +364,14 @@ extern "C" int ceph_opendir(struct ceph_mount_info *cmount, return cmount->get_client()->opendir(name, (dir_result_t **)dirpp); } -extern "C" int ceph_closedir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp) +extern "C" int ceph_closedir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->closedir((dir_result_t*)dirp); } -extern "C" struct dirent * ceph_readdir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp) +extern "C" struct dirent * ceph_readdir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp) { if (!cmount->is_mounted()) { /* Client::readdir also sets errno to signal errors. */ @@ -381,14 +381,14 @@ extern "C" struct dirent * ceph_readdir(struct ceph_mount_info *cmount, struct c return cmount->get_client()->readdir((dir_result_t*)dirp); } -extern "C" int ceph_readdir_r(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de) +extern "C" int ceph_readdir_r(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->readdir_r((dir_result_t*)dirp, de); } -extern "C" int ceph_readdirplus_r(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, +extern "C" int ceph_readdirplus_r(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, struct dirent *de, struct stat *st, int *stmask) { if (!cmount->is_mounted()) @@ -396,7 +396,7 @@ extern "C" int ceph_readdirplus_r(struct ceph_mount_info *cmount, struct ceph_di return cmount->get_client()->readdirplus_r((dir_result_t*)dirp, de, st, stmask); } -extern "C" int ceph_getdents(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, +extern "C" int ceph_getdents(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, char *buf, int buflen) { if (!cmount->is_mounted()) @@ -404,7 +404,7 @@ extern "C" int ceph_getdents(struct ceph_mount_info *cmount, struct ceph_dir_res return cmount->get_client()->getdents((dir_result_t*)dirp, buf, buflen); } -extern "C" int ceph_getdnames(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, +extern "C" int ceph_getdnames(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, char *buf, int buflen) { if (!cmount->is_mounted()) @@ -412,28 +412,28 @@ extern "C" int ceph_getdnames(struct ceph_mount_info *cmount, struct ceph_dir_re return cmount->get_client()->getdnames((dir_result_t*)dirp, buf, buflen); } -extern "C" void ceph_rewinddir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp) +extern "C" void ceph_rewinddir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp) { if (!cmount->is_mounted()) return; cmount->get_client()->rewinddir((dir_result_t*)dirp); } -extern "C" loff_t ceph_telldir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp) +extern "C" loff_t ceph_telldir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->telldir((dir_result_t*)dirp); } -extern "C" void ceph_seekdir(struct ceph_mount_info *cmount, struct ceph_dir_result *dirp, loff_t offset) +extern "C" void ceph_seekdir(class ceph_mount_info *cmount, struct ceph_dir_result *dirp, loff_t offset) { if (!cmount->is_mounted()) return; cmount->get_client()->seekdir((dir_result_t*)dirp, offset); } -extern "C" int ceph_link (struct ceph_mount_info *cmount, const char *existing, +extern "C" int ceph_link (class ceph_mount_info *cmount, const char *existing, const char *newname) { if (!cmount->is_mounted()) @@ -441,14 +441,14 @@ extern "C" int ceph_link (struct ceph_mount_info *cmount, const char *existing, return cmount->get_client()->link(existing, newname); } -extern "C" int ceph_unlink(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_unlink(class ceph_mount_info *cmount, const char *path) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->unlink(path); } -extern "C" int ceph_rename(struct ceph_mount_info *cmount, const char *from, +extern "C" int ceph_rename(class ceph_mount_info *cmount, const char *from, const char *to) { if (!cmount->is_mounted()) @@ -457,21 +457,21 @@ extern "C" int ceph_rename(struct ceph_mount_info *cmount, const char *from, } // dirs -extern "C" int ceph_mkdir(struct ceph_mount_info *cmount, const char *path, mode_t mode) +extern "C" int ceph_mkdir(class ceph_mount_info *cmount, const char *path, mode_t mode) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->mkdir(path, mode); } -extern "C" int ceph_mkdirs(struct ceph_mount_info *cmount, const char *path, mode_t mode) +extern "C" int ceph_mkdirs(class ceph_mount_info *cmount, const char *path, mode_t mode) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->mkdirs(path, mode); } -extern "C" int ceph_rmdir(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_rmdir(class ceph_mount_info *cmount, const char *path) { if (!cmount->is_mounted()) return -ENOTCONN; @@ -479,7 +479,7 @@ extern "C" int ceph_rmdir(struct ceph_mount_info *cmount, const char *path) } // symlinks -extern "C" int ceph_readlink(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_readlink(class ceph_mount_info *cmount, const char *path, char *buf, loff_t size) { if (!cmount->is_mounted()) @@ -487,7 +487,7 @@ extern "C" int ceph_readlink(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->readlink(path, buf, size); } -extern "C" int ceph_symlink(struct ceph_mount_info *cmount, const char *existing, +extern "C" int ceph_symlink(class ceph_mount_info *cmount, const char *existing, const char *newname) { if (!cmount->is_mounted()) @@ -496,7 +496,7 @@ extern "C" int ceph_symlink(struct ceph_mount_info *cmount, const char *existing } // inode stuff -extern "C" int ceph_stat(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_stat(class ceph_mount_info *cmount, const char *path, struct stat *stbuf) { if (!cmount->is_mounted()) @@ -504,7 +504,7 @@ extern "C" int ceph_stat(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->stat(path, stbuf); } -extern "C" int ceph_lstat(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_lstat(class ceph_mount_info *cmount, const char *path, struct stat *stbuf) { if (!cmount->is_mounted()) @@ -512,7 +512,7 @@ extern "C" int ceph_lstat(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->lstat(path, stbuf); } -extern "C" int ceph_setattr(struct ceph_mount_info *cmount, const char *relpath, +extern "C" int ceph_setattr(class ceph_mount_info *cmount, const char *relpath, struct stat *attr, int mask) { if (!cmount->is_mounted()) @@ -521,56 +521,56 @@ extern "C" int ceph_setattr(struct ceph_mount_info *cmount, const char *relpath, } // *xattr() calls supporting samba/vfs -extern "C" int ceph_getxattr(struct ceph_mount_info *cmount, const char *path, const char *name, void *value, size_t size) +extern "C" int ceph_getxattr(class ceph_mount_info *cmount, const char *path, const char *name, void *value, size_t size) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->getxattr(path, name, value, size); } -extern "C" int ceph_lgetxattr(struct ceph_mount_info *cmount, const char *path, const char *name, void *value, size_t size) +extern "C" int ceph_lgetxattr(class ceph_mount_info *cmount, const char *path, const char *name, void *value, size_t size) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->lgetxattr(path, name, value, size); } -extern "C" int ceph_listxattr(struct ceph_mount_info *cmount, const char *path, char *list, size_t size) +extern "C" int ceph_listxattr(class ceph_mount_info *cmount, const char *path, char *list, size_t size) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->listxattr(path, list, size); } -extern "C" int ceph_llistxattr(struct ceph_mount_info *cmount, const char *path, char *list, size_t size) +extern "C" int ceph_llistxattr(class ceph_mount_info *cmount, const char *path, char *list, size_t size) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->llistxattr(path, list, size); } -extern "C" int ceph_removexattr(struct ceph_mount_info *cmount, const char *path, const char *name) +extern "C" int ceph_removexattr(class ceph_mount_info *cmount, const char *path, const char *name) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->removexattr(path, name); } -extern "C" int ceph_lremovexattr(struct ceph_mount_info *cmount, const char *path, const char *name) +extern "C" int ceph_lremovexattr(class ceph_mount_info *cmount, const char *path, const char *name) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->lremovexattr(path, name); } -extern "C" int ceph_setxattr(struct ceph_mount_info *cmount, const char *path, const char *name, const void *value, size_t size, int flags) +extern "C" int ceph_setxattr(class ceph_mount_info *cmount, const char *path, const char *name, const void *value, size_t size, int flags) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->setxattr(path, name, value, size, flags); } -extern "C" int ceph_lsetxattr(struct ceph_mount_info *cmount, const char *path, const char *name, const void *value, size_t size, int flags) +extern "C" int ceph_lsetxattr(class ceph_mount_info *cmount, const char *path, const char *name, const void *value, size_t size, int flags) { if (!cmount->is_mounted()) return -ENOTCONN; @@ -578,33 +578,33 @@ extern "C" int ceph_lsetxattr(struct ceph_mount_info *cmount, const char *path, } /* end xattr support */ -extern "C" int ceph_chmod(struct ceph_mount_info *cmount, const char *path, mode_t mode) +extern "C" int ceph_chmod(class ceph_mount_info *cmount, const char *path, mode_t mode) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->chmod(path, mode); } -extern "C" int ceph_fchmod(struct ceph_mount_info *cmount, int fd, mode_t mode) +extern "C" int ceph_fchmod(class ceph_mount_info *cmount, int fd, mode_t mode) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->fchmod(fd, mode); } -extern "C" int ceph_chown(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_chown(class ceph_mount_info *cmount, const char *path, int uid, int gid) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->chown(path, uid, gid); } -extern "C" int ceph_fchown(struct ceph_mount_info *cmount, int fd, +extern "C" int ceph_fchown(class ceph_mount_info *cmount, int fd, int uid, int gid) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->fchown(fd, uid, gid); } -extern "C" int ceph_lchown(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_lchown(class ceph_mount_info *cmount, const char *path, int uid, int gid) { if (!cmount->is_mounted()) @@ -613,7 +613,7 @@ extern "C" int ceph_lchown(struct ceph_mount_info *cmount, const char *path, } -extern "C" int ceph_utime(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_utime(class ceph_mount_info *cmount, const char *path, struct utimbuf *buf) { if (!cmount->is_mounted()) @@ -621,7 +621,7 @@ extern "C" int ceph_utime(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->utime(path, buf); } -extern "C" int ceph_truncate(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_truncate(class ceph_mount_info *cmount, const char *path, loff_t size) { if (!cmount->is_mounted()) @@ -630,7 +630,7 @@ extern "C" int ceph_truncate(struct ceph_mount_info *cmount, const char *path, } // file ops -extern "C" int ceph_mknod(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_mknod(class ceph_mount_info *cmount, const char *path, mode_t mode, dev_t rdev) { if (!cmount->is_mounted()) @@ -638,7 +638,7 @@ extern "C" int ceph_mknod(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->mknod(path, mode, rdev); } -extern "C" int ceph_open(struct ceph_mount_info *cmount, const char *path, +extern "C" int ceph_open(class ceph_mount_info *cmount, const char *path, int flags, mode_t mode) { if (!cmount->is_mounted()) @@ -646,7 +646,7 @@ extern "C" int ceph_open(struct ceph_mount_info *cmount, const char *path, return cmount->get_client()->open(path, flags, mode); } -extern "C" int ceph_open_layout(struct ceph_mount_info *cmount, const char *path, int flags, +extern "C" int ceph_open_layout(class ceph_mount_info *cmount, const char *path, int flags, mode_t mode, int stripe_unit, int stripe_count, int object_size, const char *data_pool) { if (!cmount->is_mounted()) @@ -655,14 +655,14 @@ extern "C" int ceph_open_layout(struct ceph_mount_info *cmount, const char *path stripe_count, object_size, data_pool); } -extern "C" int ceph_close(struct ceph_mount_info *cmount, int fd) +extern "C" int ceph_close(class ceph_mount_info *cmount, int fd) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->close(fd); } -extern "C" loff_t ceph_lseek(struct ceph_mount_info *cmount, int fd, +extern "C" loff_t ceph_lseek(class ceph_mount_info *cmount, int fd, loff_t offset, int whence) { if (!cmount->is_mounted()) @@ -670,7 +670,7 @@ extern "C" loff_t ceph_lseek(struct ceph_mount_info *cmount, int fd, return cmount->get_client()->lseek(fd, offset, whence); } -extern "C" int ceph_read(struct ceph_mount_info *cmount, int fd, char *buf, +extern "C" int ceph_read(class ceph_mount_info *cmount, int fd, char *buf, loff_t size, loff_t offset) { if (!cmount->is_mounted()) @@ -678,7 +678,7 @@ extern "C" int ceph_read(struct ceph_mount_info *cmount, int fd, char *buf, return cmount->get_client()->read(fd, buf, size, offset); } -extern "C" int ceph_write(struct ceph_mount_info *cmount, int fd, const char *buf, +extern "C" int ceph_write(class ceph_mount_info *cmount, int fd, const char *buf, loff_t size, loff_t offset) { if (!cmount->is_mounted()) @@ -686,28 +686,28 @@ extern "C" int ceph_write(struct ceph_mount_info *cmount, int fd, const char *bu return cmount->get_client()->write(fd, buf, size, offset); } -extern "C" int ceph_ftruncate(struct ceph_mount_info *cmount, int fd, loff_t size) +extern "C" int ceph_ftruncate(class ceph_mount_info *cmount, int fd, loff_t size) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->ftruncate(fd, size); } -extern "C" int ceph_fsync(struct ceph_mount_info *cmount, int fd, int syncdataonly) +extern "C" int ceph_fsync(class ceph_mount_info *cmount, int fd, int syncdataonly) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->fsync(fd, syncdataonly); } -extern "C" int ceph_fstat(struct ceph_mount_info *cmount, int fd, struct stat *stbuf) +extern "C" int ceph_fstat(class ceph_mount_info *cmount, int fd, struct stat *stbuf) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->fstat(fd, stbuf); } -extern "C" int ceph_sync_fs(struct ceph_mount_info *cmount) +extern "C" int ceph_sync_fs(class ceph_mount_info *cmount) { if (!cmount->is_mounted()) return -ENOTCONN; @@ -715,7 +715,7 @@ extern "C" int ceph_sync_fs(struct ceph_mount_info *cmount) } -extern "C" int ceph_get_file_stripe_unit(struct ceph_mount_info *cmount, int fh) +extern "C" int ceph_get_file_stripe_unit(class ceph_mount_info *cmount, int fh) { struct ceph_file_layout l; int r; @@ -728,7 +728,7 @@ extern "C" int ceph_get_file_stripe_unit(struct ceph_mount_info *cmount, int fh) return l.fl_stripe_unit; } -extern "C" int ceph_get_path_stripe_unit(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_get_path_stripe_unit(class ceph_mount_info *cmount, const char *path) { struct ceph_file_layout l; int r; @@ -741,7 +741,7 @@ extern "C" int ceph_get_path_stripe_unit(struct ceph_mount_info *cmount, const c return l.fl_stripe_unit; } -extern "C" int ceph_get_file_stripe_count(struct ceph_mount_info *cmount, int fh) +extern "C" int ceph_get_file_stripe_count(class ceph_mount_info *cmount, int fh) { struct ceph_file_layout l; int r; @@ -754,7 +754,7 @@ extern "C" int ceph_get_file_stripe_count(struct ceph_mount_info *cmount, int fh return l.fl_stripe_count; } -extern "C" int ceph_get_path_stripe_count(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_get_path_stripe_count(class ceph_mount_info *cmount, const char *path) { struct ceph_file_layout l; int r; @@ -767,7 +767,7 @@ extern "C" int ceph_get_path_stripe_count(struct ceph_mount_info *cmount, const return l.fl_stripe_count; } -extern "C" int ceph_get_file_object_size(struct ceph_mount_info *cmount, int fh) +extern "C" int ceph_get_file_object_size(class ceph_mount_info *cmount, int fh) { struct ceph_file_layout l; int r; @@ -780,7 +780,7 @@ extern "C" int ceph_get_file_object_size(struct ceph_mount_info *cmount, int fh) return l.fl_object_size; } -extern "C" int ceph_get_path_object_size(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_get_path_object_size(class ceph_mount_info *cmount, const char *path) { struct ceph_file_layout l; int r; @@ -793,7 +793,7 @@ extern "C" int ceph_get_path_object_size(struct ceph_mount_info *cmount, const c return l.fl_object_size; } -extern "C" int ceph_get_file_pool(struct ceph_mount_info *cmount, int fh) +extern "C" int ceph_get_file_pool(class ceph_mount_info *cmount, int fh) { struct ceph_file_layout l; int r; @@ -806,7 +806,7 @@ extern "C" int ceph_get_file_pool(struct ceph_mount_info *cmount, int fh) return l.fl_pg_pool; } -extern "C" int ceph_get_path_pool(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_get_path_pool(class ceph_mount_info *cmount, const char *path) { struct ceph_file_layout l; int r; @@ -819,7 +819,7 @@ extern "C" int ceph_get_path_pool(struct ceph_mount_info *cmount, const char *pa return l.fl_pg_pool; } -extern "C" int ceph_get_file_pool_name(struct ceph_mount_info *cmount, int fh, char *buf, size_t len) +extern "C" int ceph_get_file_pool_name(class ceph_mount_info *cmount, int fh, char *buf, size_t len) { struct ceph_file_layout l; int r; @@ -838,7 +838,7 @@ extern "C" int ceph_get_file_pool_name(struct ceph_mount_info *cmount, int fh, c return name.length(); } -extern "C" int ceph_get_pool_name(struct ceph_mount_info *cmount, int pool, char *buf, size_t len) +extern "C" int ceph_get_pool_name(class ceph_mount_info *cmount, int pool, char *buf, size_t len) { if (!cmount->is_mounted()) return -ENOTCONN; @@ -851,7 +851,7 @@ extern "C" int ceph_get_pool_name(struct ceph_mount_info *cmount, int pool, char return name.length(); } -extern "C" int ceph_get_path_pool_name(struct ceph_mount_info *cmount, const char *path, char *buf, size_t len) +extern "C" int ceph_get_path_pool_name(class ceph_mount_info *cmount, const char *path, char *buf, size_t len) { struct ceph_file_layout l; int r; @@ -870,7 +870,7 @@ extern "C" int ceph_get_path_pool_name(struct ceph_mount_info *cmount, const cha return name.length(); } -extern "C" int ceph_get_file_layout(struct ceph_mount_info *cmount, int fh, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool) +extern "C" int ceph_get_file_layout(class ceph_mount_info *cmount, int fh, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool) { struct ceph_file_layout l; int r; @@ -891,7 +891,7 @@ extern "C" int ceph_get_file_layout(struct ceph_mount_info *cmount, int fh, int return 0; } -extern "C" int ceph_get_path_layout(struct ceph_mount_info *cmount, const char *path, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool) +extern "C" int ceph_get_path_layout(class ceph_mount_info *cmount, const char *path, int *stripe_unit, int *stripe_count, int *object_size, int *pg_pool) { struct ceph_file_layout l; int r; @@ -912,7 +912,7 @@ extern "C" int ceph_get_path_layout(struct ceph_mount_info *cmount, const char * return 0; } -extern "C" int ceph_get_file_replication(struct ceph_mount_info *cmount, int fh) +extern "C" int ceph_get_file_replication(class ceph_mount_info *cmount, int fh) { struct ceph_file_layout l; int r; @@ -926,7 +926,7 @@ extern "C" int ceph_get_file_replication(struct ceph_mount_info *cmount, int fh) return rep; } -extern "C" int ceph_get_path_replication(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_get_path_replication(class ceph_mount_info *cmount, const char *path) { struct ceph_file_layout l; int r; @@ -940,40 +940,40 @@ extern "C" int ceph_get_path_replication(struct ceph_mount_info *cmount, const c return rep; } -extern "C" int ceph_set_default_file_stripe_unit(struct ceph_mount_info *cmount, +extern "C" int ceph_set_default_file_stripe_unit(class ceph_mount_info *cmount, int stripe) { // this option no longer exists return -EOPNOTSUPP; } -extern "C" int ceph_set_default_file_stripe_count(struct ceph_mount_info *cmount, +extern "C" int ceph_set_default_file_stripe_count(class ceph_mount_info *cmount, int count) { // this option no longer exists return -EOPNOTSUPP; } -extern "C" int ceph_set_default_object_size(struct ceph_mount_info *cmount, int size) +extern "C" int ceph_set_default_object_size(class ceph_mount_info *cmount, int size) { // this option no longer exists return -EOPNOTSUPP; } -extern "C" int ceph_set_default_file_replication(struct ceph_mount_info *cmount, +extern "C" int ceph_set_default_file_replication(class ceph_mount_info *cmount, int replication) { // this option no longer exists return -EOPNOTSUPP; } -extern "C" int ceph_set_default_preferred_pg(struct ceph_mount_info *cmount, int osd) +extern "C" int ceph_set_default_preferred_pg(class ceph_mount_info *cmount, int osd) { // this option no longer exists return -EOPNOTSUPP; } -extern "C" int ceph_get_file_extent_osds(struct ceph_mount_info *cmount, int fh, +extern "C" int ceph_get_file_extent_osds(class ceph_mount_info *cmount, int fh, loff_t offset, loff_t *length, int *osds, int nosds) { if (nosds < 0) @@ -999,7 +999,7 @@ extern "C" int ceph_get_file_extent_osds(struct ceph_mount_info *cmount, int fh, return vosds.size(); } -extern "C" int ceph_get_osd_crush_location(struct ceph_mount_info *cmount, +extern "C" int ceph_get_osd_crush_location(class ceph_mount_info *cmount, int osd, char *path, size_t len) { if (!cmount->is_mounted()) @@ -1037,7 +1037,7 @@ extern "C" int ceph_get_osd_crush_location(struct ceph_mount_info *cmount, return needed; } -extern "C" int ceph_get_osd_addr(struct ceph_mount_info *cmount, int osd, +extern "C" int ceph_get_osd_addr(class ceph_mount_info *cmount, int osd, struct sockaddr_storage *addr) { if (!cmount->is_mounted()) @@ -1056,7 +1056,7 @@ extern "C" int ceph_get_osd_addr(struct ceph_mount_info *cmount, int osd, return 0; } -extern "C" int ceph_get_file_stripe_address(struct ceph_mount_info *cmount, int fh, +extern "C" int ceph_get_file_stripe_address(class ceph_mount_info *cmount, int fh, loff_t offset, struct sockaddr_storage *addr, int naddr) { vector address; @@ -1083,7 +1083,7 @@ extern "C" int ceph_get_file_stripe_address(struct ceph_mount_info *cmount, int return address.size(); } -extern "C" int ceph_localize_reads(struct ceph_mount_info *cmount, int val) +extern "C" int ceph_localize_reads(class ceph_mount_info *cmount, int val) { if (!cmount->is_mounted()) return -ENOTCONN; @@ -1094,33 +1094,33 @@ extern "C" int ceph_localize_reads(struct ceph_mount_info *cmount, int val) return 0; } -extern "C" CephContext *ceph_get_mount_context(struct ceph_mount_info *cmount) +extern "C" CephContext *ceph_get_mount_context(class ceph_mount_info *cmount) { return cmount->get_ceph_context(); } -extern "C" int ceph_debug_get_fd_caps(struct ceph_mount_info *cmount, int fd) +extern "C" int ceph_debug_get_fd_caps(class ceph_mount_info *cmount, int fd) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->get_caps_issued(fd); } -extern "C" int ceph_debug_get_file_caps(struct ceph_mount_info *cmount, const char *path) +extern "C" int ceph_debug_get_file_caps(class ceph_mount_info *cmount, const char *path) { if (!cmount->is_mounted()) return -ENOTCONN; return cmount->get_client()->get_caps_issued(path); } -extern "C" int ceph_get_stripe_unit_granularity(struct ceph_mount_info *cmount) +extern "C" int ceph_get_stripe_unit_granularity(class ceph_mount_info *cmount) { if (!cmount->is_mounted()) return -ENOTCONN; return CEPH_MIN_STRIPE_UNIT; } -extern "C" int ceph_get_pool_id(struct ceph_mount_info *cmount, const char *pool_name) +extern "C" int ceph_get_pool_id(class ceph_mount_info *cmount, const char *pool_name) { if (!cmount->is_mounted()) return -ENOTCONN; @@ -1137,7 +1137,7 @@ extern "C" int ceph_get_pool_id(struct ceph_mount_info *cmount, const char *pool return (int)pool_id; } -extern "C" int ceph_get_pool_replication(struct ceph_mount_info *cmount, int pool_id) +extern "C" int ceph_get_pool_replication(class ceph_mount_info *cmount, int pool_id) { if (!cmount->is_mounted()) return -ENOTCONN; diff --git a/src/librados/RadosClient.h b/src/librados/RadosClient.h index 4f616d453313..2244788d876a 100644 --- a/src/librados/RadosClient.h +++ b/src/librados/RadosClient.h @@ -25,9 +25,9 @@ #include "IoCtxImpl.h" -class AuthAuthorizer; +struct AuthAuthorizer; class CephContext; -class Connection; +struct Connection; struct md_config_t; class Message; class MWatchNotify; diff --git a/src/librbd/AioRequest.h b/src/librbd/AioRequest.h index ac74a99dad31..7625bdd7ff3a 100644 --- a/src/librbd/AioRequest.h +++ b/src/librbd/AioRequest.h @@ -14,8 +14,8 @@ namespace librbd { - class AioCompletion; - class ImageCtx; + struct AioCompletion; + struct ImageCtx; /** * This class represents an I/O operation to a single RBD data object. diff --git a/src/librbd/LibrbdWriteback.h b/src/librbd/LibrbdWriteback.h index ba8ff1f114d1..4f35aa4b0673 100644 --- a/src/librbd/LibrbdWriteback.h +++ b/src/librbd/LibrbdWriteback.h @@ -15,7 +15,7 @@ class Mutex; namespace librbd { - class ImageCtx; + struct ImageCtx; class LibrbdWriteback : public WritebackHandler { public: diff --git a/src/mds/CDentry.h b/src/mds/CDentry.h index 7990b0ce9158..0d2445a525fe 100644 --- a/src/mds/CDentry.h +++ b/src/mds/CDentry.h @@ -33,7 +33,7 @@ using namespace std; class CInode; class CDir; -class MDRequest; +struct MDRequest; class Message; class Anchor; diff --git a/src/mds/CDir.h b/src/mds/CDir.h index 11f4a76d0477..7cf2b6a43d7d 100644 --- a/src/mds/CDir.h +++ b/src/mds/CDir.h @@ -40,7 +40,7 @@ class MDCluster; class Context; class bloom_filter; -class ObjectOperation; +struct ObjectOperation; ostream& operator<<(ostream& out, class CDir& dir); class CDir : public MDSCacheObject { diff --git a/src/mds/CInode.h b/src/mds/CInode.h index 82c234743084..8e760220c148 100644 --- a/src/mds/CInode.h +++ b/src/mds/CInode.h @@ -47,10 +47,10 @@ class Message; class CInode; class MDCache; class LogSegment; -class SnapRealm; +struct SnapRealm; class Session; class MClientCaps; -class ObjectOperation; +struct ObjectOperation; class EMetaBlob; ostream& operator<<(ostream& out, CInode& in); diff --git a/src/mds/Locker.h b/src/mds/Locker.h index b39eff175d6d..0c9931a47345 100644 --- a/src/mds/Locker.h +++ b/src/mds/Locker.h @@ -29,10 +29,10 @@ class Session; class CDir; class CInode; class CDentry; -class Mutation; -class MDRequest; +struct Mutation; +struct MDRequest; class EMetaBlob; -class SnapRealm; +struct SnapRealm; class Message; @@ -284,13 +284,13 @@ public: private: friend class C_MDL_CheckMaxSize; friend class C_MDL_RequestInodeFileCaps; - friend class C_Locker_FileUpdate_finish; + friend struct C_Locker_FileUpdate_finish; friend class C_Locker_RetryCapRelease; // -- client leases -- public: - void handle_client_lease(class MClientLease *m); + void handle_client_lease(struct MClientLease *m); void issue_client_lease(CDentry *dn, client_t client, bufferlist &bl, utime_t now, Session *session); void revoke_client_leases(SimpleLock *lock); diff --git a/src/mds/LogSegment.h b/src/mds/LogSegment.h index 44c794257383..723267da1168 100644 --- a/src/mds/LogSegment.h +++ b/src/mds/LogSegment.h @@ -31,7 +31,7 @@ class CDir; class CInode; class CDentry; class MDS; -class MDSlaveUpdate; +struct MDSlaveUpdate; class LogSegment { public: diff --git a/src/mds/MDCache.h b/src/mds/MDCache.h index 36a322c6324a..b4b57da84b2b 100644 --- a/src/mds/MDCache.h +++ b/src/mds/MDCache.h @@ -51,23 +51,23 @@ class MDirUpdate; class MDentryLink; class MDentryUnlink; class MLock; -class MMDSFindIno; -class MMDSFindInoReply; -class MMDSOpenIno; -class MMDSOpenInoReply; +struct MMDSFindIno; +struct MMDSFindInoReply; +struct MMDSOpenIno; +struct MMDSOpenInoReply; class Message; class MClientRequest; class MMDSSlaveRequest; -class MClientSnap; +struct MClientSnap; class MMDSFragmentNotify; class ESubtreeMap; -class Mutation; -class MDRequest; -class MDSlaveUpdate; +struct Mutation; +struct MDRequest; +struct MDSlaveUpdate; // flags for predirty_journal_parents() @@ -801,8 +801,8 @@ protected: void handle_open_ino(MMDSOpenIno *m); void handle_open_ino_reply(MMDSOpenInoReply *m); friend class C_MDC_OpenInoBacktraceFetched; - friend class C_MDC_OpenInoTraverseDir; - friend class C_MDC_OpenInoParentOpened; + friend struct C_MDC_OpenInoTraverseDir; + friend struct C_MDC_OpenInoParentOpened; public: void kick_open_ino_peers(int who); diff --git a/src/mds/Server.h b/src/mds/Server.h index 6e8f27509fb0..cf1ef5b85b5f 100644 --- a/src/mds/Server.h +++ b/src/mds/Server.h @@ -19,8 +19,8 @@ class PerfCounters; class LogEvent; -class MDRequest; -class Mutation; +struct MDRequest; +struct Mutation; class EMetaBlob; class EUpdate; class MMDSSlaveRequest; diff --git a/src/mds/SessionMap.h b/src/mds/SessionMap.h index f3e7e0990e1c..e960ac5a4f93 100644 --- a/src/mds/SessionMap.h +++ b/src/mds/SessionMap.h @@ -28,7 +28,7 @@ using __gnu_cxx::hash_map; #include "mdstypes.h" class CInode; -class MDRequest; +struct MDRequest; #include "CInode.h" #include "Capability.h" diff --git a/src/mds/SimpleLock.h b/src/mds/SimpleLock.h index 0eff040845f8..7684e9a128e4 100644 --- a/src/mds/SimpleLock.h +++ b/src/mds/SimpleLock.h @@ -38,7 +38,7 @@ inline const char *get_lock_type_name(int t) { } } -class Mutation; +struct Mutation; extern "C" { #include "locks.h" diff --git a/src/mds/events/EMetaBlob.h b/src/mds/events/EMetaBlob.h index b91303a13283..6edcf96b5447 100644 --- a/src/mds/events/EMetaBlob.h +++ b/src/mds/events/EMetaBlob.h @@ -27,7 +27,7 @@ class MDS; class MDLog; class LogSegment; -class MDSlaveUpdate; +struct MDSlaveUpdate; /* * a bunch of metadata in the journal diff --git a/src/mds/snap.h b/src/mds/snap.h index 068b6f17073b..0216e624bbae 100644 --- a/src/mds/snap.h +++ b/src/mds/snap.h @@ -48,7 +48,7 @@ struct SnapRealm; struct CapabilityGroup; class CInode; class MDCache; -class MDRequest; +struct MDRequest; diff --git a/src/mon/AuthMonitor.h b/src/mon/AuthMonitor.h index 30d567a77caf..130616aedcd6 100644 --- a/src/mon/AuthMonitor.h +++ b/src/mon/AuthMonitor.h @@ -27,9 +27,9 @@ using namespace std; #include "mon/MonitorDBStore.h" class MMonCommand; -class MAuth; +struct MAuth; class MAuthMon; -class MMonGlobalID; +struct MMonGlobalID; class KeyRing; #define MIN_GLOBAL_ID 0x1000 diff --git a/src/mon/DataHealthService.h b/src/mon/DataHealthService.h index a17171509c17..337e7a450f75 100644 --- a/src/mon/DataHealthService.h +++ b/src/mon/DataHealthService.h @@ -25,7 +25,7 @@ #include "common/config.h" #include "global/signal_handler.h" -class MMonHealth; +struct MMonHealth; class DataHealthService : public HealthService diff --git a/src/mon/MonClient.h b/src/mon/MonClient.h index f82714ecf377..64a399a197ab 100644 --- a/src/mon/MonClient.h +++ b/src/mon/MonClient.h @@ -37,10 +37,10 @@ class MonMap; class MMonMap; class MMonGetVersion; class MMonGetVersionReply; -class MMonSubscribeAck; +struct MMonSubscribeAck; class MMonCommandAck; class MCommandReply; -class MAuthReply; +struct MAuthReply; class MAuthRotating; class LogClient; class AuthSupported; diff --git a/src/mon/Monitor.h b/src/mon/Monitor.h index cb1f4138a252..f8043917cefc 100644 --- a/src/mon/Monitor.h +++ b/src/mon/Monitor.h @@ -95,12 +95,12 @@ class MMonGetVersion; class MMonSync; class MMonScrub; class MMonProbe; -class MMonSubscribe; +struct MMonSubscribe; class MAuthRotating; -class MRoute; -class MForward; -class MTimeCheck; -class MMonHealth; +struct MRoute; +struct MForward; +struct MTimeCheck; +struct MMonHealth; #define COMPAT_SET_LOC "feature_set" diff --git a/src/mon/OSDMonitor.h b/src/mon/OSDMonitor.h index f66c676b53d9..04f7cf5b1963 100644 --- a/src/mon/OSDMonitor.h +++ b/src/mon/OSDMonitor.h @@ -305,8 +305,8 @@ private: } }; - bool preprocess_remove_snaps(class MRemoveSnaps *m); - bool prepare_remove_snaps(class MRemoveSnaps *m); + bool preprocess_remove_snaps(struct MRemoveSnaps *m); + bool prepare_remove_snaps(struct MRemoveSnaps *m); public: OSDMonitor(Monitor *mn, Paxos *p, string service_name) diff --git a/src/msg/DispatchQueue.h b/src/msg/DispatchQueue.h index 82d6ba12c8d0..df7313035923 100644 --- a/src/msg/DispatchQueue.h +++ b/src/msg/DispatchQueue.h @@ -31,7 +31,7 @@ class DispatchQueue; class Pipe; class SimpleMessenger; class Message; -class Connection; +struct Connection; /** * The DispatchQueue contains all the Pipes which have Messages diff --git a/src/os/FileStore.h b/src/os/FileStore.h index 86d267dddf1c..8595dd63add6 100644 --- a/src/os/FileStore.h +++ b/src/os/FileStore.h @@ -254,7 +254,7 @@ private: void op_queue_reserve_throttle(Op *o); void op_queue_release_throttle(Op *o); void _journaled_ahead(OpSequencer *osr, Op *o, Context *ondisk); - friend class C_JournaledAhead; + friend struct C_JournaledAhead; int open_journal(); diff --git a/src/osd/ClassHandler.h b/src/osd/ClassHandler.h index f7c80f9454b0..ae416bc6bfcb 100644 --- a/src/osd/ClassHandler.h +++ b/src/osd/ClassHandler.h @@ -12,7 +12,7 @@ class ClassHandler { public: - class ClassData; + struct ClassData; struct ClassMethod { struct ClassHandler::ClassData *cls; diff --git a/src/osd/OSD.h b/src/osd/OSD.h index 82a251d9a80a..4f2b5daf0d1f 100644 --- a/src/osd/OSD.h +++ b/src/osd/OSD.h @@ -851,7 +851,7 @@ private: void test_ops(std::string command, std::string args, ostream& ss); friend class TestOpsSocketHook; TestOpsSocketHook *test_ops_hook; - friend class C_CompleteSplits; + friend struct C_CompleteSplits; // -- op queue -- @@ -1176,7 +1176,7 @@ protected: void start_waiting_for_healthy(); bool _is_healthy(); - friend class C_OSD_GetVersion; + friend struct C_OSD_GetVersion; // -- alive -- epoch_t up_thru_wanted; @@ -1688,7 +1688,7 @@ public: void handle_signal(int signum); void handle_rep_scrub(MOSDRepScrub *m); - void handle_scrub(class MOSDScrub *m); + void handle_scrub(struct MOSDScrub *m); void handle_osd_ping(class MOSDPing *m); void handle_op(OpRequestRef op); diff --git a/src/osd/OpRequest.h b/src/osd/OpRequest.h index e72f03d1d778..fc8a8ab82c94 100644 --- a/src/osd/OpRequest.h +++ b/src/osd/OpRequest.h @@ -25,7 +25,7 @@ #include "common/TrackedOp.h" #include "osd/osd_types.h" -class OpRequest; +struct OpRequest; typedef std::tr1::shared_ptr OpRequestRef; class OpHistory { set > arrived; diff --git a/src/osd/PG.h b/src/osd/PG.h index d4679ce4fd84..14ac7c9fac52 100644 --- a/src/osd/PG.h +++ b/src/osd/PG.h @@ -890,7 +890,7 @@ public: void unreg_next_scrub(); void replica_scrub( - class MOSDRepScrub *op, + struct MOSDRepScrub *op, ThreadPool::TPHandle &handle); void sub_op_scrub_map(OpRequestRef op); void sub_op_scrub_reserve(OpRequestRef op); diff --git a/src/osd/ReplicatedPG.h b/src/osd/ReplicatedPG.h index 41c8106ea000..2342cc8895ae 100644 --- a/src/osd/ReplicatedPG.h +++ b/src/osd/ReplicatedPG.h @@ -444,7 +444,7 @@ protected: friend class C_OSD_OpCommit; friend class C_OSD_OpApplied; - friend class C_OnPushCommit; + friend struct C_OnPushCommit; // projected object info map object_contexts; @@ -884,7 +884,7 @@ protected: pg->unlock(); } }; - friend class C_OSD_CompletedPull; + friend struct C_OSD_CompletedPull; struct C_OSD_AppliedRecoveredObjectReplica : public Context { ReplicatedPGRef pg; C_OSD_AppliedRecoveredObjectReplica(ReplicatedPG *p) : diff --git a/src/osd/Watch.h b/src/osd/Watch.h index d912e91ed2c8..1c9fa28cb654 100644 --- a/src/osd/Watch.h +++ b/src/osd/Watch.h @@ -31,7 +31,7 @@ class OSDService; class ReplicatedPG; void intrusive_ptr_add_ref(ReplicatedPG *pg); void intrusive_ptr_release(ReplicatedPG *pg); -class ObjectContext; +struct ObjectContext; class MWatchNotify; class Watch; @@ -42,7 +42,7 @@ class Notify; typedef std::tr1::shared_ptr NotifyRef; typedef std::tr1::weak_ptr WNotifyRef; -class CancelableContext; +struct CancelableContext; /** * Notify tracks the progress of a particular notify diff --git a/src/osdc/Filer.h b/src/osdc/Filer.h index 86ff601fdc24..d1cfb4f52755 100644 --- a/src/osdc/Filer.h +++ b/src/osdc/Filer.h @@ -248,7 +248,7 @@ class Filer { utime_t mtime, int flags, Context *oncommit); - void _do_purge_range(class PurgeRange *pr, int fin); + void _do_purge_range(struct PurgeRange *pr, int fin); /* * probe diff --git a/src/osdc/Journaler.h b/src/osdc/Journaler.h index dfc2115c18bd..51241c197e87 100644 --- a/src/osdc/Journaler.h +++ b/src/osdc/Journaler.h @@ -221,7 +221,7 @@ private: void _issue_prezero(); void _prezeroed(int r, uint64_t from, uint64_t len); - friend class C_Journaler_Prezero; + friend struct C_Journaler_Prezero; // only init_headers when following or first reading off-disk void init_headers(Header& h) { diff --git a/src/osdc/ObjectCacher.h b/src/osdc/ObjectCacher.h index ac2833b9ea68..7d5ce6fad04e 100644 --- a/src/osdc/ObjectCacher.h +++ b/src/osdc/ObjectCacher.h @@ -45,7 +45,7 @@ class ObjectCacher { public: CephContext *cct; class Object; - class ObjectSet; + struct ObjectSet; class C_ReadFinish; typedef void (*flush_set_callback_t) (void *p, ObjectSet *oset); @@ -165,7 +165,7 @@ class ObjectCacher { int ref; ObjectCacher *oc; sobject_t oid; - friend class ObjectSet; + friend struct ObjectSet; public: ObjectSet *oset; diff --git a/src/osdc/Objecter.h b/src/osdc/Objecter.h index a321c409c9b9..090fb331611d 100644 --- a/src/osdc/Objecter.h +++ b/src/osdc/Objecter.h @@ -737,7 +737,7 @@ public: // read public: - class OSDSession; + struct OSDSession; struct Op { OSDSession *session; diff --git a/src/rados_sync.cc b/src/rados_sync.cc index c55e5b21bea1..d16894c6ea97 100644 --- a/src/rados_sync.cc +++ b/src/rados_sync.cc @@ -346,13 +346,13 @@ Xattr::~Xattr() { free(data); } -bool Xattr::operator==(const struct Xattr &rhs) const { +bool Xattr::operator==(const class Xattr &rhs) const { if (len != rhs.len) return false; return (memcmp(data, rhs.data, len) == 0); } -bool Xattr::operator!=(const struct Xattr &rhs) const { +bool Xattr::operator!=(const class Xattr &rhs) const { return !((*this) == rhs); } diff --git a/src/rados_sync.h b/src/rados_sync.h index 83ced528f694..0f7226e0239d 100644 --- a/src/rados_sync.h +++ b/src/rados_sync.h @@ -139,8 +139,8 @@ class Xattr { public: Xattr(char *data_, ssize_t len_); ~Xattr(); - bool operator==(const struct Xattr &rhs) const; - bool operator!=(const struct Xattr &rhs) const; + bool operator==(const class Xattr &rhs) const; + bool operator!=(const class Xattr &rhs) const; char *data; ssize_t len; diff --git a/src/rgw/rgw_common.cc b/src/rgw/rgw_common.cc index 8a281775d077..ef0a2604d51a 100644 --- a/src/rgw/rgw_common.cc +++ b/src/rgw/rgw_common.cc @@ -93,7 +93,7 @@ is_err() const } -req_info::req_info(CephContext *cct, struct RGWEnv *e) : env(e) { +req_info::req_info(CephContext *cct, class RGWEnv *e) : env(e) { method = env->get("REQUEST_METHOD"); script_uri = env->get("SCRIPT_URI", cct->_conf->rgw_script_uri.c_str()); request_uri = env->get("REQUEST_URI", cct->_conf->rgw_request_uri.c_str()); @@ -122,7 +122,7 @@ void req_info::rebuild_from(req_info& src) } -req_state::req_state(CephContext *_cct, struct RGWEnv *e) : cct(_cct), cio(NULL), op(OP_UNKNOWN), +req_state::req_state(CephContext *_cct, class RGWEnv *e) : cct(_cct), cio(NULL), op(OP_UNKNOWN), bucket_cors(NULL), has_acl_header(false), os_auth_token(NULL), info(_cct, e) { diff --git a/src/rgw/rgw_common.h b/src/rgw/rgw_common.h index 8e4126de2718..6e8273ec7b6a 100644 --- a/src/rgw/rgw_common.h +++ b/src/rgw/rgw_common.h @@ -757,7 +757,7 @@ struct RGWBucketStats struct req_state; -struct RGWEnv; +class RGWEnv; class RGWClientIO; @@ -846,7 +846,7 @@ struct req_state { req_info info; - req_state(CephContext *_cct, struct RGWEnv *e); + req_state(CephContext *_cct, class RGWEnv *e); ~req_state(); }; diff --git a/src/rgw/rgw_metadata.h b/src/rgw/rgw_metadata.h index 50649b6f9010..df4d3f73afa7 100644 --- a/src/rgw/rgw_metadata.h +++ b/src/rgw/rgw_metadata.h @@ -11,7 +11,7 @@ class RGWRados; class JSONObj; -class RGWObjVersionTracker; +struct RGWObjVersionTracker; struct obj_version; @@ -158,7 +158,7 @@ public: int unlock(int shard_id, string& zone_id, string& owner_id); }; -class RGWMetadataLogData; +struct RGWMetadataLogData; class RGWMetadataManager { map handlers; diff --git a/src/rgw/rgw_swift_auth.h b/src/rgw/rgw_swift_auth.h index 670a339210d9..6d50d945641f 100644 --- a/src/rgw/rgw_swift_auth.h +++ b/src/rgw/rgw_swift_auth.h @@ -37,7 +37,7 @@ public: RGWRESTMgr_SWIFT_Auth() {} virtual ~RGWRESTMgr_SWIFT_Auth() {} - virtual RGWRESTMgr *get_resource_mgr(struct req_state *s, const string& uri) { + virtual RGWRESTMgr *get_resource_mgr(struct req_state *s, const string& uri, string *out_uri) { return this; } virtual RGWHandler *get_handler(struct req_state *s) { diff --git a/src/rgw/rgw_tools.h b/src/rgw/rgw_tools.h index 3e673c1656bd..9adaee484cc1 100644 --- a/src/rgw/rgw_tools.h +++ b/src/rgw/rgw_tools.h @@ -7,7 +7,7 @@ #include "rgw_common.h" class RGWRados; -class RGWObjVersionTracker; +struct RGWObjVersionTracker; struct obj_version;