Project

General

Profile

Bug #11517

Libcephfs: Doesn't check file's open mode when do read/write

Added by Haomai Wang over 3 years ago. Updated over 2 years ago.

Status:
Resolved
Priority:
High
Assignee:
Category:
-
Target version:
-
Start date:
05/01/2015
Due date:
% Done:

0%

Source:
other
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
libcephfs
Labels (FS):
Pull request ID:

Description

Something like this:

fd = cephfs_open(path, O_WRONLY|O_CREAT, 0)
cephfs.read(fd, buf, 0, 10) // ok, but actually we need to return error

Associated revisions

Revision eae97f8d (diff)
Added by Yan, Zheng about 3 years ago

client: check if Fh is readable before read

Fixes: #11517
Signed-off-by: Yan, Zheng <>

History

#1 Updated by Greg Farnum over 3 years ago

  • Priority changed from Normal to High

#2 Updated by Sage Weil over 3 years ago

  • Project changed from Ceph to fs
  • Category deleted (24)
  • Regression set to No

#3 Updated by Sage Weil over 3 years ago

  • Category set to 44

#4 Updated by Greg Farnum over 3 years ago

  • Assignee set to Zheng Yan

#5 Updated by Greg Farnum about 3 years ago

This is done, need to find PR and close!

#6 Updated by Greg Farnum about 3 years ago

Oh, this might not be done for read-only fds. Need to check.

#7 Updated by Zheng Yan about 3 years ago

  • Status changed from New to Need Review

#8 Updated by Greg Farnum almost 3 years ago

  • Status changed from Need Review to Resolved

#9 Updated by Greg Farnum over 2 years ago

  • Component(FS) libcephfs added

Also available in: Atom PDF