diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/internal/tpax_driver_impl.h | 15 | ||||
-rw-r--r-- | src/logic/tpax_archive_append.c | 2 |
2 files changed, 17 insertions, 0 deletions
diff --git a/src/internal/tpax_driver_impl.h b/src/internal/tpax_driver_impl.h index ea02185..9860717 100644 --- a/src/internal/tpax_driver_impl.h +++ b/src/internal/tpax_driver_impl.h @@ -79,6 +79,7 @@ struct tpax_driver_ctx_impl { char ** prefcap; char * prefptr[64]; struct tpax_dirent_buffer * dirents; + struct tpax_dirent * dirmark; void * dirbuff; void * bufaddr; size_t bufsize; @@ -212,6 +213,20 @@ static inline struct tpax_dirent_buffer * tpax_get_driver_dirents(const struct t return ictx->dirents; } +static inline struct tpax_dirent * tpax_get_driver_dirmark(const struct tpax_driver_ctx * dctx) +{ + struct tpax_driver_ctx_impl * ictx; + ictx = tpax_get_driver_ictx(dctx); + return ictx->dirmark; +} + +static inline void tpax_set_driver_dirmark(const struct tpax_driver_ctx * dctx, struct tpax_dirent * dirent) +{ + struct tpax_driver_ctx_impl * ictx; + ictx = tpax_get_driver_ictx(dctx); + ictx->dirmark = dirent; +} + static inline off_t tpax_get_unit_hpos(const struct tpax_unit_ctx * uctx) { struct tpax_unit_ctx_impl * ictx; diff --git a/src/logic/tpax_archive_append.c b/src/logic/tpax_archive_append.c index 3dcac5c..4526aaf 100644 --- a/src/logic/tpax_archive_append.c +++ b/src/logic/tpax_archive_append.c @@ -271,6 +271,8 @@ static int tpax_archive_append_queue_item( dentbuf->cdent = (struct tpax_dirent *)cap; dentbuf->nfree -= needed; + tpax_set_driver_dirmark(dctx,cdent); + return 0; } |