Re: [PATCH 07/23] multipathd: move conf destruction into separate function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2020-09-28 at 13:03 -0500, Benjamin Marzinski wrote:
>  
> > -	if (logsink == 1)
> > +	if (logsink == 1) {
> > +		logsink = 0;
> >  		log_thread_stop();
> 
> It seems like log_thread_stop() could just do something like
> 
> pthread_t log_thr_save = log_thr;
> log_thr = (pthread_t)0;
> 
> at the start, and then you would continue to get syslog logging, even
> when the log thread stopped. It's racy, but all the other threads
> (except the log_thread, obviously) should be stopped. Or am I not
> understanding the purpose of doing this?

I guess we could do this, yes (although I think (pthread_t)0 should be
avoided, but that's a different issue. Let me have another look.

Regards,
Martin


--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel




[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux