Move ntfs_index_entry_mark_dirty() from index.h to index.c. (Szaka)
parent
aa5ee310d0
commit
561cb42743
|
@ -54,7 +54,7 @@ xx/xx/2006 - x.xx.x - .
|
|||
- Fix GUID to string conversion. (Anton)
|
||||
- Fix some byte-order conversion for u32 variables that used le16
|
||||
conversion macros. (zhanglinbao, Yuval)
|
||||
- Spelling mistake fixes in debug logging strings. (Yuval)
|
||||
- Spelling mistake fixes. (Yuval)
|
||||
- Remove inline keywords from static non-one-liners. (Szaka, Yuval)
|
||||
- Memory leak fixes. (Yura, Yuval)
|
||||
- Use memmove() in compress.c for moving overlapping blocks instead
|
||||
|
@ -62,6 +62,7 @@ xx/xx/2006 - x.xx.x - .
|
|||
- Change ntfs_collate()'s signature to take size_t's. (Yuval)
|
||||
- Move ntfs_is_collation_rule_supported() from collate.h to collate.c
|
||||
and rewrite it to be clearer. (Yuval)
|
||||
- Move ntfs_index_entry_mark_dirty() to index.c. (Szaka)
|
||||
|
||||
21/06/2006 - 1.13.1 - Various fixes.
|
||||
|
||||
|
|
|
@ -126,26 +126,6 @@ extern char *ntfs_ie_filename_get(INDEX_ENTRY *ie);
|
|||
extern void ntfs_ie_filename_dump(INDEX_ENTRY *ie);
|
||||
extern void ntfs_ih_filename_dump(INDEX_HEADER *ih);
|
||||
|
||||
/**
|
||||
* ntfs_index_entry_mark_dirty - mark an index entry dirty
|
||||
* @ictx: ntfs index context describing the index entry
|
||||
*
|
||||
* Mark the index entry described by the index entry context @ictx dirty.
|
||||
*
|
||||
* If the index entry is in the index root attribute, simply mark the inode
|
||||
* containing the index root attribute dirty. This ensures the mftrecord, and
|
||||
* hence the index root attribute, will be written out to disk later.
|
||||
*
|
||||
* If the index entry is in an index block belonging to the index allocation
|
||||
* attribute, set ib_dirty to TRUE, thus index block will be updated during
|
||||
* ntfs_index_ctx_put.
|
||||
*/
|
||||
static inline void ntfs_index_entry_mark_dirty(ntfs_index_context *ictx)
|
||||
{
|
||||
if (ictx->is_in_root)
|
||||
ntfs_inode_mark_dirty(ictx->actx->ntfs_ino);
|
||||
else
|
||||
ictx->ib_dirty = TRUE;
|
||||
}
|
||||
extern void ntfs_index_entry_mark_dirty(ntfs_index_context *ictx);
|
||||
|
||||
#endif /* _NTFS_INDEX_H */
|
||||
|
|
|
@ -46,6 +46,28 @@
|
|||
#include "bitmap.h"
|
||||
#include "support.h"
|
||||
|
||||
/**
|
||||
* ntfs_index_entry_mark_dirty - mark an index entry dirty
|
||||
* @ictx: ntfs index context describing the index entry
|
||||
*
|
||||
* Mark the index entry described by the index entry context @ictx dirty.
|
||||
*
|
||||
* If the index entry is in the index root attribute, simply mark the inode
|
||||
* containing the index root attribute dirty. This ensures the mftrecord, and
|
||||
* hence the index root attribute, will be written out to disk later.
|
||||
*
|
||||
* If the index entry is in an index block belonging to the index allocation
|
||||
* attribute, set ib_dirty to TRUE, thus index block will be updated during
|
||||
* ntfs_index_ctx_put.
|
||||
*/
|
||||
void ntfs_index_entry_mark_dirty(ntfs_index_context *ictx)
|
||||
{
|
||||
if (ictx->is_in_root)
|
||||
ntfs_inode_mark_dirty(ictx->actx->ntfs_ino);
|
||||
else
|
||||
ictx->ib_dirty = TRUE;
|
||||
}
|
||||
|
||||
static s64 ntfs_ib_vcn_to_pos(ntfs_index_context *icx, VCN vcn)
|
||||
{
|
||||
return vcn << icx->vcn_size_bits;
|
||||
|
|
Loading…
Reference in New Issue