common/ceph_fs: set mode default is -1 for func ceph_flags_to_mode.

Signed-off-by: Jianpeng Ma <jianpeng.ma@intel.com>
This commit is contained in:
Jianpeng Ma 2015-08-13 17:03:52 +08:00
parent 79e776865e
commit 43529a5883

View File

@ -37,7 +37,8 @@ int ceph_file_layout_is_valid(const struct ceph_file_layout *layout)
int ceph_flags_to_mode(int flags)
{
int mode = 0;
/* because CEPH_FILE_MODE_PIN is zero, so mode = -1 is error */
int mode = -1;
#ifdef O_DIRECTORY /* fixme */
if ((flags & O_DIRECTORY) == O_DIRECTORY)