btrfs-progs: tasks info->id is a pthread_t and should not set to -1
Signed-off-by: Silvio Fricke <silvio.fricke@gmail.com> Signed-off-by: David Sterba <dsterba@suse.com>
This commit is contained in:
parent
f22e40f978
commit
6a1336fab6
|
@ -51,7 +51,7 @@ int task_start(struct task_info *info)
|
|||
info->private_data);
|
||||
|
||||
if (ret)
|
||||
info->id = -1;
|
||||
info->id = 0;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
@ -64,7 +64,7 @@ void task_stop(struct task_info *info)
|
|||
if (info->id > 0) {
|
||||
pthread_cancel(info->id);
|
||||
pthread_join(info->id, NULL);
|
||||
info->id = -1;
|
||||
info->id = 0;
|
||||
}
|
||||
|
||||
if (info->periodic.timer_fd) {
|
||||
|
|
Loading…
Reference in New Issue