mirror of
https://github.com/amadvance/snapraid.git
synced 2026-12-01 12:26:38 -05:00
Use different thread when writing content file
This should reduce the possibility that the same memory error is going to affect all the written content files in the same way.
This commit is contained in:
parent
80476c480b
commit
fcf7c44197
3 changed files with 323 additions and 161 deletions
|
|
@ -54,12 +54,7 @@ typedef int64_t data_off_t;
|
|||
struct snapraid_content {
|
||||
char content[PATH_MAX]; /**< Path of the content file. */
|
||||
uint64_t device; /**< Device identifier. */
|
||||
uint32_t crc; /**< Expected crc. */
|
||||
#if HAVE_PTHREAD_CREATE
|
||||
pthread_t thread; /**< Thread used for verification. */
|
||||
#else
|
||||
void* retval; /**< Result of the verification. */
|
||||
#endif
|
||||
void* context; /**< Context used for multithread operations. */
|
||||
tommy_node node; /**< Next node in the list. */
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue