예제 #1
0
def inode_number_to_block(offset, inode_num):
    inode = inode_number_to_inode(inode_num)
    o = offset / blockLayer.get_block_size()
    b = inode.index_to_block_number(o)
    return blockLayer.block_number_to_block(b)
예제 #2
0
파일: fileLayer.py 프로젝트: kitsully/PFS
 def inode_to_block(self, byte_offset):
     o = byte_offset / blockLayer.get_block_size()
     b = self.index_to_block_number(o)
     return blockLayer.block_number_to_block(b)